るりまサーチ

最速Rubyリファレンスマニュアル検索!
121件ヒット [1-100件を表示] (0.045秒)
トップページ > クエリ:self[x] > クエリ:level[x]

別のキーワード

  1. object yield_self
  2. _builtin yield_self
  3. _builtin self
  4. tracepoint self
  5. codeobject document_self

検索結果

<< 1 2 > >>

Syslog::Logger#level -> Integer (18123.0)

self に設定されたログレベルを返します。

...
self
に設定されたログレベルを返します。

ログレベルは Logger と互換性があります。

@see Syslog::Logger#level=...

Thread#safe_level -> Integer (6145.0)

self のセーフレベルを返します。カレントスレッドの safe_level は、$SAFE と同じです。

...
self
のセーフレベルを返します。カレントスレッドの
safe_level は、$SAFE と同じです。

Ruby 2.6 から$SAFEがプロセスグローバルになったため、このメソッドは obsolete になりました。

セーフレベルについてはspec/safelevelを参照し...
...てください。

//emlist[例][ruby]{
thr = Thread.new { $SAFE = 1; sleep }
Thread.current.safe_level # => 0
thr.safe_level # => 1
//}...

Syslog::Logger#level=(val) (6123.0)

self のログレベルを引数 val で指定した値に設定します。

...
self
のログレベルを引数 val で指定した値に設定します。

@param val ログレベルを指定します。

@see Syslog::Logger#level...

Refinement#import_methods(*modules) -> self (119.0)

モジュールからメソッドをインポートします。

...ソッドだけしか
インポートできないことに注意してください。

//emlist[][ruby]{
module StrUtils
def indent(level)
' ' * level + self
end
end

module M
refine String do
import_methods StrUtils
end
end

using M
p "foo".indent(3) # => " foo"

module M
refine...

ruby 1.6 feature (114.0)

ruby 1.6 feature ruby version 1.6 は安定版です。この版での変更はバグ修正がメイン になります。

...の戻り値

以下のメソッドの戻り値が正しくなりました。((<ruby-bugs-ja:PR#205>))

* ((<Enumerable/each_with_index>)) が self を返すようになった(以前は nil)
* ((<Process/Process.setpgrp>)) が返す値が不定だった。
* ((<String/ljust>)), ((<String/rju...
...なくても常に dup した文字列を返すようになった

: 2002-03-08 class variable

((<ruby-talk:35122>))

class C
class << self
def test
@@cv = 5
p @@cv
end
end

test
end
=> -:5:in `test': uninitialized class variable @...
...ror
LoadError
Float
Binding
SignalException
Module
-:6:in `method_missing': stack level too deep (SystemStackError)

: %q(...)

% 記法によるリテラル表記でその区切り文字として英数字を指定
できなくな...

絞り込み条件を変える

irb (66.0)

irb は Interactive Ruby の略です。 irb を使うと、Ruby の式を標準入力から簡単に入力・実行することができます。

...(分数と行列の計算ができる)
-d $DEBUG を true にする (ruby -d と同じ)
-w ruby -w と同じ
-W[level=2] ruby -W と同じ
-r library ruby -r と同じ
-I ruby -I と同じ
-U ruby -U と同じ
-E...
...オブジェクトの作成方法を 0 から 3 で設定する。
(IRB::Context 参照)
--single-irb irb 中で self を実行して得られるオブジェクトをサブ irb と共
有する
--irb_debug n irb のデバッグレベル...
...ョンを指定したのと同じ効果が得られます。

IRB.conf[:AUTO_INDENT] = false
IRB.conf[:BACK_TRACE_LIMIT] = 16
IRB.conf[:DEBUG_LEVEL] = 1
IRB.conf[:ECHO] = nil
IRB.conf[:EVAL_HISTORY] = nil
IRB.conf[:HISTORY_FILE] = nil
IRB.conf[:IGNORE_EOF] = true
IRB.conf[:IGNORE_SIG...
...~/.irbrc を読み込まない
-d $DEBUG を true にする (ruby -d と同じ)
-w ruby -w と同じ
-W[level=2] ruby -W と同じ
-r library ruby -r と同じ
-I ruby -I と同じ
-U ruby -U と同じ
-E...

Ruby用語集 (60.0)

Ruby用語集 A B C D E F G I J M N O R S Y

...N の加算を行うと、Integer 側では相手が未知のため、自身を引数に
まず相手側の N#coerce を呼ぶ。N#coerce では self と引数を、既に加算が定義された
オブジェクトのペアに変換して返す。Integer 側ではそれらの加算を行う。...
...込みや
アプリケーションソフト組込みに適した特徴を持つ。

https://mruby.org/

: main
トップレベルにおける self。Object クラスのインスタンスである。

===[a:N] N

: nil
NilClass の唯一のインスタンス。また、そのオブジェク...
...課していた。
しかし、Ruby 2.7 でこの機構は実質的に無効化されて、
Ruby 3.2 で削除された。

参照:spec/safelevel

: 鬼雲
: Onigmo
Ruby 2.0 以降採用されている正規表現エンジン。鬼車のフォーク。

参照:spec/regexp

: 鬼車
: O...
...ドである。

: トップレベル
: top level
スクリプトの一番外側のコンテキスト。つまり、すべてのモジュール定義、
クラス定義、メソッド定義の外側である。

トップレベルでは main が self となる。

===[a:na] な

: 名前空間...

パターンマッチ (48.0)

パターンマッチ * patterns * variable_binding * variable_pinning * matching_non_primitive_objects * guard_clauses * current_feature_status * pattern_syntax * some_undefined_behavior_examples

...st[][ruby]{
jane = {school: 'high', schools: [{id: 1, level: 'middle'}, {id: 2, level: 'high'}]}
john = {school: 'high', schools: [{id: 1, level: 'middle'}]}

case jane
in school:, schools: [*, {id:, level: ^school}] # select the last school, level should match
"matched. school: #{id}"
else
"not...
...matched"
end
#=> "matched. school: 2"

case john # 指定された school の level は "high" だが、最後の school はマッチしない
in school:, schools: [*, {id:, level: ^school}]
"matched. school: #{id}"
else
"not matched"
end
#=> "not matched"
//}


===[a:matching_non_primitive_obj...
...n c
"not matched"
end
a #=> 未定義
c #=> 未定義
//}

//emlist[deconstruct メソッドや deconstruct_keys メソッドが呼び出された回数][ruby]{
$i = 0
ary = [0]
def ary.deconstruct
$i += 1
self

end
case ary
in [0, 1]
"not matched"
in [0]
"matched"
end
$i #=> 未定義
//}...
...matched"
end
#=> "matched. school: 2"

case john # 指定された school の level は "high" だが、最後の school はマッチしない
in school:, schools: [*, {id:, level: ^school}]
"matched. school: #{id}"
else
"not matched"
end
#=> "not matched"
//}

ローカル変数に加えてイ...

ruby 1.8.3 feature (24.0)

ruby 1.8.3 feature *((<ruby 1.8 feature>)) *((<ruby 1.8.2 feature>))

...ead.new{
$SAFE = 3
class Hoge
def foo
puts "safe level: #{$SAFE}"
end
end
}
th.join
p $SAFE
Hoge.new.foo

$ ruby-1.8.2 mthd_taint.rb
0
"safe level: 0"

$ ruby-1.8.3 mthd_taint.rb
0
mthd_taint.rb:11:in `foo':...
...101 #=> @@foo は Fred クラスのクラス変数ではない。
end

def Fred.foo_foo
class_variable_set(:@@foo, 101) # self が Fred クラス自身であることに注意。クラス変数 @@foo に値をセットする。
end

Fred.foo # メソ...
...singleton class [ruby] [change]
特異クラスは複製できなくなりました。((<ruby-talk:142749>))

$ ruby-1.8.3 -e 'class << "str"; self end.dup'
-e:1:in `initialize_copy': can't copy singleton class (TypeError)
from -e:1

=== 2005-05-15
: Pathname#unlink [lib] [comp...

NEWS for Ruby 2.0.0 (18.0)

NEWS for Ruby 2.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...たファイルのパスを返します

* Module
* 追加: Module#prepend 指定したモジュールを self の継承チェインの先頭に
「追加する」ことで self の定数、メソッド、モジュール変数を「上書き」します。
* 追加: Module.prepended...
...ad of BINARY.

* TracePoint
* new class. This class is replacement of set_trace_func.
Easy to use and efficient implementation.

* toplevel
* added method:
* added main.define_method which defines a global function.
* added main.using, which imports refinements into the...
...rs, StringIO#codepoints

* syslog
* 追加: Syslog::Logger Syslog上に Logger API を提供します
* 追加: Syslog::Priority, Syslog::Level, Syslog::Option, Syslog::Macros
システムで定義されている定数を簡単に検知するために導入しました。

* tmpdir...

絞り込み条件を変える

<< 1 2 > >>