678件ヒット
[1-100件を表示]
(0.033秒)
別のキーワード
ライブラリ
- ビルトイン (478)
- benchmark (12)
- date (2)
-
fiddle
/ import (12) - json (12)
-
rexml
/ document (36) - securerandom (8)
- set (9)
- timeout (37)
- un (12)
- uri (12)
クラス
- Array (10)
- DateTime (2)
- FalseClass (60)
- Object (8)
-
REXML
:: Text (12) - Set (12)
- String (21)
- Symbol (21)
- Time (307)
モジュール
- Benchmark (12)
-
Fiddle
:: Importer (12) -
GC
:: Profiler (24) -
JSON
:: Generator :: GeneratorMethods :: FalseClass (12) - Kernel (52)
-
REXML
:: Security (24) - SecureRandom (8)
- Timeout (21)
- URI (12)
キーワード
- & (12)
- - (24)
- FALSE (8)
- Rubyで使われる記号の意味(正規表現の複雑な記号は除く) (12)
- ^ (12)
- alphanumeric (8)
- at (34)
- bmbm (12)
- casecmp (24)
- casecmp? (18)
-
decode
_ www _ form _ component (12) -
deconstruct
_ keys (4) -
entity
_ expansion _ text _ limit (12) -
entity
_ expansion _ text _ limit= (12) - fiddle (12)
- gm (24)
- inspect (12)
- intersect? (4)
- intersection (18)
- local (24)
- mktime (24)
- new (43)
- now (12)
- nsec (12)
- report (12)
- result (12)
-
ruby 1
. 6 feature (12) -
rubygems
/ security (12) - sleep (24)
- struct (12)
- subsec (12)
- timeout (37)
-
to
_ a (12) -
to
_ i (12) -
to
_ json (12) -
to
_ s (12) -
tv
_ nsec (12) -
tv
_ sec (12) -
tv
_ usec (12) - usec (12)
- utc (24)
-
wait
_ writable (12) - | (12)
検索結果
先頭5件
-
rubygems
/ security (32054.0) -
このライブラリは暗号署名を RubyGems パッケージに使用するために使用します。
...このライブラリは暗号署名を RubyGems パッケージに使用するために使用します。
=== 署名付きの Gem パッケージ
==== 目次
* 概要
* 解説
* コマンドラインオプション
* OpenSSL リファレンス
* Bugs / TODO
* 作者について
==== 概......要
このライブラリは暗号署名を RubyGems パッケージに使用するために使用します。
以下のセクションでは、署名付きの Gem パッケージを作成する方法を
ステップバイステップで解説しています。
==== 解説
@todo メソッドでは......lib2-Ruby-0.5.0.gem
data.tar.gz
data.tar.gz.sig
metadata.gz
metadata.gz.sig
さあ、署名を検証してみましょう。以下のように "-P HighSecurity" オプションを
付けて Gem をインストールしてみてください。
# install the gem with using the securit... -
Time
# sec -> Integer (18125.0) -
秒を整数で返します。
...秒を整数で返します。
//emlist[][ruby]{
p Time.mktime(2000, 1, 1).sec # => 0
//}
通常は0から59を返しますが、うるう秒の場合は60を返します。
//emlist[][ruby]{
ENV['TZ'] = 'right/UTC'
p Time.mktime(2005, 12, 31, 23, 59, 60).sec # => 60
//}... -
String
# casecmp(other) -> -1 | 0 | 1 | nil (6112.0) -
String#<=> と同様に文字列の順序を比較しますが、 アルファベットの大文字小文字の違いを無視します。
...ruby]{
"aBcDeF".casecmp("abcde") #=> 1
"aBcDeF".casecmp("abcdef") #=> 0
"aBcDeF".casecmp("abcdefg") #=> -1
"abcdef".casecmp("ABCDEF") #=> 0
//}
nil は文字列のエンコーディングが非互換の時に返されます。
//emlist[][ruby]{
"\u{e4 f6 fc}".encode("ISO-8859-1").casec......String#casecmp? と違って大文字小文字の違いを無視するのは
Unicode 全体ではなく、A-Z/a-z だけです。
@param other self と比較する文字列
//emlist[例][ruby]{
"aBcDeF".casecmp("abcde") #=> 1
"aBcDeF".casecmp("abcdef") #=> 0
"aBcDeF".casecmp("abcdefg")......#=> -1
"abcdef".casecmp("ABCDEF") #=> 0
//}
nil は文字列のエンコーディングが非互換の時に返されます。
//emlist[][ruby]{
"\u{e4 f6 fc}".encode("ISO-8859-1").casecmp("\u{c4 d6 dc}") #=> nil
//}
@see String#<=>, Encoding.compatible?... -
String
# casecmp?(other) -> bool | nil (6112.0) -
大文字小文字の違いを無視し文字列を比較します。 文字列が一致する場合には true を返し、一致しない場合には false を返します。
...m other self と比較する文字列
//emlist[例][ruby]{
"abcdef".casecmp?("abcde") #=> false
"aBcDeF".casecmp?("abcdef") #=> true
"abcdef".casecmp?("abcdefg") #=> false
"abcdef".casecmp?("ABCDEF") #=> true
"\u{e4 f6 fc}".casecmp?("\u{c4 d6 dc}") #=> true
//}
nil は文字列の......エンコーディングが非互換の時に返されます。
//emlist[][ruby]{
"\u{e4 f6 fc}".encode("ISO-8859-1").casecmp?("\u{c4 d6 dc}") #=> nil
//}
@see String#casecmp... -
Symbol
# casecmp(other) -> -1 | 0 | 1 | nil (6112.0) -
Symbol#<=> と同様にシンボルに対応する文字列の順序を比較しますが、 アルファベットの大文字小文字の違いを無視します。
...other 比較対象のシンボルを指定します。
//emlist[][ruby]{
:aBcDeF.casecmp(:abcde) #=> 1
:aBcDeF.casecmp(:abcdef) #=> 0
:aBcDeF.casecmp(:abcdefg) #=> -1
:abcdef.casecmp(:ABCDEF) #=> 0
:"\u{e4 f6 fc}".casecmp(:"\u{c4 d6 dc}") #=> 1
//}
other がシンボルではない場......合や、文字列のエンコーディングが非互換の場合は、nil を返します。
//emlist[][ruby]{
:foo.casecmp("foo") #=> nil
"\u{e4 f6 fc}".encode("ISO-8859-1").to_sym.casecmp(:"\u{c4 d6 dc}") #=> nil
//}
@see String#casecmp, Symbol#<=>, Symbol#casecmp?......ymbol#casecmp? と違って大文字小文字の違いを無視するのは
Unicode 全体ではなく、A-Z/a-z だけです。
@param other 比較対象のシンボルを指定します。
//emlist[][ruby]{
:aBcDeF.casecmp(:abcde) #=> 1
:aBcDeF.casecmp(:abcdef) #=> 0
:aBcDeF.casecmp(:abcd......efg) #=> -1
:abcdef.casecmp(:ABCDEF) #=> 0
:"\u{e4 f6 fc}".casecmp(:"\u{c4 d6 dc}") #=> 1
//}
other がシンボルではない場合や、文字列のエンコーディングが非互換の場合は、nil を返します。
//emlist[][ruby]{
:foo.casecmp("foo") #=> nil
"\u{e4 f6 fc}".encod......e("ISO-8859-1").to_sym.casecmp(:"\u{c4 d6 dc}") #=> nil
//}
@see String#casecmp, Symbol#<=>, Symbol#casecmp?... -
Symbol
# casecmp?(other) -> bool | nil (6112.0) -
大文字小文字の違いを無視しシンボルを比較します。 シンボルが一致する場合には true を返し、一致しない場合には false を返します。
...較対象のシンボルを指定します。
//emlist[][ruby]{
:abcdef.casecmp?(:abcde) #=> false
:aBcDeF.casecmp?(:abcdef) #=> true
:abcdef.casecmp?(:abcdefg) #=> false
:abcdef.casecmp?(:ABCDEF) #=> true
:"\u{e4 f6 fc}".casecmp?(:"\u{c4 d6 dc}") #=> true
//}
other がシンボルで......はない場合や、文字列のエンコーディングが非互換の場合は、nil を返します。
//emlist[][ruby]{
:foo.casecmp?("foo") #=> nil
"\u{e4 f6 fc}".encode("ISO-8859-1").to_sym.casecmp?(:"\u{c4 d6 dc}") #=> nil
//}
@see String#casecmp?, Symbol#casecmp... -
Array
# intersect?(other) -> bool (6106.0) -
other と共通の要素が少なくとも1個あれば true を、なければ false を返します。
...other と共通の要素が少なくとも1個あれば true を、なければ false を返します。
//emlist[例][ruby]{
a = [ 1, 2, 3 ]
b = [ 3, 4, 5 ]
c = [ 5, 6, 7 ]
a.intersect?(b) # => true
a.intersect?(c) # => false
//}... -
Array
# intersection(*other _ arrays) -> Array (6106.0) -
自身と引数に渡された配列の共通要素を新しい配列として返します。 要素が重複する場合は、そのうちの1つのみを返します。 要素の順序は自身の順序を維持します。
...合に発生します。
intersectionはObject#hashとObject#eql?を使って比較を行います。
//emlist[例][ruby]{
[1, 1, 3, 5].intersection([3, 2, 1]) # => [1, 3]
["a", "b", "z"].intersection(["a", "b", "c"], ["b"]) # => ["b"]
["a"].intersection......# => ["a"]
//}
@see Set#intersection, Array#&... -
Time
# nsec -> Integer (6106.0) -
時刻のナノ秒の部分を整数で返します。
...。
//emlist[][ruby]{
t = Time.local(2000,1,2,3,4,5,6)
p "%10.9f" % t.to_f # => "946749845.000005960"
p t.nsec # => 6000
//}
IEEE 754 浮動小数点数で表現できる精度が違うため、Time#to_fの最小
の桁とnsecの最小の桁は異なります。nsecで表される... -
Time
# subsec -> Integer | Rational (6106.0) -
時刻を表す分数を返します。
...返します。
Rational を返す場合があります。
//emlist[][ruby]{
t = Time.local(2000,1,2,3,4,5,6)
p "%10.9f" % t.to_f # => "946749845.000005960"
p t.subsec #=> (3/500000)
//}
to_f の値と subsec の値の下のほうの桁の値は異なる場合があります。
と......いうのは IEEE 754 double はそれを表すのに十分な精度を
持たないからです。subsec で得られる値が正確です。...