るりまサーチ

最速Rubyリファレンスマニュアル検索!
128件ヒット [1-100件を表示] (0.033秒)

別のキーワード

  1. uri default_port
  2. _builtin default
  3. generic default_port
  4. socket ai_default
  5. socket ip_default_multicast_ttl

検索結果

<< 1 2 > >>

Rake::Cloneable#dup -> object (18125.0)

自身と同じクラスのオブジェクトを作成後、自身のインスタンス変数を 全て新たに作成したオブジェクトにコピーします。

...ます。

//emlist[][ruby]{
# Rakefile での記載例とする

task default: :test_rake_app
task :test_rake_app do
file_list = FileList['a.c', 'b.c']
file_list.freeze
dup
= file_list.dup
clone = file_list.clone
dup
.exclude("a.c") # => ["b.c"]
clone.exclude("a.c") # => can't modify f...

Kernel$$DEFAULT_OUTPUT -> IO (6131.0)

$> の別名

...$> の別名

require "English"

dout = $DEFAULT_OUTPUT.dup
$DEFAULT_OUTPUT.reopen("out.txt", "w")
print "foo"
$DEFAULT_OUTPUT.close
$DEFAULT_OUTPUT = dout
p "bar" # => bar
p File.read("out.txt") #=> foo...

Gem::DependencyInstaller::DEFAULT_OPTIONS -> Hash (6113.0)

自身を初期化する際に使用するデフォルトのオプションです。

...トのオプションです。

:env_shebang => false,
:domain => :both, # HACK dup
:force => false,
:format_executable => false, # HACK dup
:ignore_dependencies => false,
:security_policy => nil, # HACK NoSecurity requires OpenSSL. A...

NEWS for Ruby 2.0.0 (114.0)

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

...します

* Hash
* 追加: Hash#to_h 明示的に変換するメソッドです。Array#to_a に似ています
* 拡張: Hash#default_proc= default proc をクリアするために nil を渡せるようになりました

* IO
* 非推奨: IO#lines, #bytes, #chars, #codepoints...
...at thread creation.
default
: 128KB (32bit CPU) or 256KB (64bit CPU).
* RUBY_THREAD_MACHINE_STACK_SIZE: machine stack size used at thread
creation. default: 512KB or 1024KB.
* RUBY_FIBER_VM_STACK_SIZE: vm stack size used at fiber creation.
default
: 64KB or 128KB....
...otected method now returns false
unless the second argument is true.

* Object#respond_to_missing?, Object#initialize_clone, Object#initialize_dup
* private になりました

* Thread#join, Thread#value
* 上を参照

* Mutex#lock, Mutex#unlock, Mutex#try_lock, Mutex#synchronize...

ruby 1.6 feature (36.0)

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

...合が修正されたのだそうです。
((<ruby-win32:273>))

: 2002-08-12 Hash#==

Hash オブジェクトはデフォルト値 (((<Hash/default>))) も == で等しい
ときに等しいとみなされるようになりました。

p Hash.new("foo") == Hash.new("bar")

=>...
...x]
[]
=> ruby 1.6.7 (2002-08-01) [i586-linux]
["bar"]

: 2002-06-13 Hash[]

Hash[] で、キーとなる文字列を dup & freeze していませんでした。

a = "key"
h = Hash[a,"val"]
h.keys[0].upcase!
p a
=> ruby 1.6.7 (2...
...プの dup を close_write するとエラーになっていました。
((<ruby-dev:17155>))

open("|-","r+") {|f|
if f
f.dup.close_write
else
sleep 1
end
}

=> ruby 1.6.7 (2002-03-01) [i586-linux]
-:3:in `close_write': closing non-duplex IO f...

絞り込み条件を変える

1.6.8から1.8.0への変更点(まとめ) (30.0)

1.6.8から1.8.0への変更点(まとめ) * ((<1.6.8から1.8.0への変更点(まとめ)/インタプリタの変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたクラス/モジュール>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたメソッド>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加された定数>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張されたクラス/メソッド(互換性のある変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/変更されたクラス/メソッド(互換性のない変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/文法の変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/正規表現>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Marshal>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Windows 対応>)) * ((<1.6.8から1.8.0への変更点(まとめ)/廃止された(される予定の)機能>)) * ((<1.6.8から1.8.0への変更点(まとめ)/ライブラリ>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張ライブラリAPI>)) * ((<1.6.8から1.8.0への変更点(まとめ)/バグ修正>)) * ((<1.6.8から1.8.0への変更点(まとめ)/サポートプラットフォームの追加>))

...new]
: ((<Hash#merge!|Hash/merge!>)) [new]

追加。Hash#merge は、hash.dup.update と同じ。
Hash#merge! は、Hash#update の別名 ((<ruby-talk:59777>)), ((<ruby-dev:19463>))

: ((<Hash#default_proc|Hash/default_proc>)) [new]

追加 ((<ruby-dev:17966>))

=== IO

: ((<IO/IO.sysopen>))...
...(<組み込み関数/trap>)) [compat]

あるシグナルに対して、SIG_DFL や SIG_IGN が割り当てられていた場合、
文字列 "DEFAULT" や "IGNORE" を返すようになりました(以前は、nil を返
していました) ((<ruby-talk:67860>))

: ((<組み込み関数/syste...
...)

: ((<Array#collect|Array/collect>)) [bug]
: ((<Array#map|Array/map>)) [bug]

Array#collect がブロックを伴わない場合に self.dup を返していました。
そのため、Array 以外を返すことがありました((<ruby-list:30480>))。

Foo = Class.new Array...

Ruby用語集 (24.0)

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

...//blade.nagaokaut.ac.jp/ruby/

: bundled gem
標準添付ライブラリーの gem のうち、アンインストールできるもの。

default gem、標準添付ライブラリー

: Bundler
特定の Ruby アプリケーションで使用する gem とそのバージョンを Gemfile...
...uby では、文字列は
エンコーディング情報をもたないバイト列であった。

→エンコーディング

===[a:D] D

: default gem
標準添付ライブラリーの gem のうち、アンインストールできないもの。

→ bundled gem、標準添付ライブ...
...読み出すメソッドは foo とし、@foo に値を設定する
メソッドは foo= とする。

: 浅い複製
: shallow copy
配列を dup メソッドで複製したとき、配列の要素オブジェクトまでは複製されない。
ハッシュも同様である。このよう...

ruby 1.8.4 feature (24.0)

ruby 1.8.4 feature ruby 1.8.4 での ruby 1.8.3 からの変更点です。

...command table and manipulate other IPs (for reason of security).
# Now, a IP object can be controlled by only its master IP or the
# default IP.
#
# * ext/tk/lib/remote-tk.rb: add restriction to manipulate.
#
# * ext/tk/tcltklib.c (ip_is_slave_of_p): add TclTkIp#slave_o...
...#Wed Nov 2 19:03:06 2005 Hidetoshi NAGAI <nagai@ai.kyutech.ac.jp>
#
# * ext/tcltklib/tcltklib.c (ip_rbUpdateObjCmd,
# ip_rb_threadUpdateObjCmd): passed improper flags to DoOneEvent().
#
# * ext/tk/tkutil.c: use rb_obj_respond_to() instead of rb_respond_to().
#

update...
...#
# * lib/webrick/config.rb (Config::FileHandler): :UserDir should be nil.
# It is harmful to permit the access to ~/public_html by default.
# suggested by Hiroyuki Iwatsuki.

WEBrick::Config::FileHandler[:UserDir]のデフォルト値が
"public_html"からnilにな...

クラス/メソッドの定義 (18.0)

クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined

...オブジェクトに対してだけ有効になります。
Object#clone で生成したオブジェクトには引き継がれますが,
Object#dup で生成したオブジェクトには引き継がれません.

rescue/ensure 節を指定し、例外処理ができます。
例外処理に...
...list[例][ruby]{
def fact(n)
if n == 1 then
1
else
n * fact(n-1)
end
end
//}

文法:

def メソッド名 ['(' [arg0 ['=' default0]] ... [',' '*' rest_args [, post ...]] [',' key1: [val1]] ... [',' '**'kwrest] [',' '&' block_arg]`)']
式.. (body)
[rescu...
...メソッド定義

//emlist[例][ruby]{
def foo.test
print "this is foo\n"
end
//}

文法:

def 式 `.' 識別子 [`(' [引数 [`=' default]] ... [`,' `*' 引数 ]`)']
式..
[rescue [error_type,..] [=> evar] [then]
式..]..
[else...
<< 1 2 > >>