352件ヒット
[1-100件を表示]
(0.125秒)
種類
- インスタンスメソッド (187)
- 特異メソッド (143)
- クラス (22)
ライブラリ
- ビルトイン (22)
- csv (121)
-
net
/ http (77) -
net
/ imap (11) - openssl (44)
- prettyprint (22)
-
rexml
/ document (44) -
webrick
/ httpresponse (11)
クラス
- CSV (121)
- Method (22)
-
Net
:: HTTP (66) -
Net
:: HTTPResponse (11) -
Net
:: IMAP (11) -
OpenSSL
:: Digest (22) - PrettyPrint (22)
-
REXML
:: Document (22) -
REXML
:: Element (11) -
WEBrick
:: HTTPResponse (11)
モジュール
-
OpenSSL
:: Buffering (11)
検索結果
先頭5件
-
OpenSSL
:: Buffering # <<(s) -> self (24100.0) -
文字列 s を書き込みます。
...文字列 s を書き込みます。
IO#<< と同様です。
@param s 出力する文字列... -
OpenSSL
:: Digest # <<(data) -> self (24100.0) -
data でダイジェストオブジェクトの内部状態を更新します。
data でダイジェストオブジェクトの内部状態を更新します。
@param data 入力文字列 -
PrettyPrint
. singleline _ format(output = & # 39;& # 39; , maxwidth = 79 , newline = "\n" , genspace = lambda{|n| & # 39; & # 39; * n}) {|pp| . . . } -> object (15406.0) -
PrettyPrint オブジェクトを生成し、それを引数としてブロックを実行します。 PrettyPrint.format に似ていますが、改行しません。
...PrettyPrint オブジェクトを生成し、それを引数としてブロックを実行します。
PrettyPrint.format に似ていますが、改行しません。
引数 maxwidth, newline と genspace は無視されます。ブロック中の breakable の実行は、
改行せずに text......の実行であるかのように扱います。
@param output 出力先を指定します。output は << メソッドを持っていなければなりません。
@param maxwidth 無視されます。
@param newline 無視されます。
@param genspace 無視されます。... -
Method
# inspect -> String (12312.0) -
self を読みやすい文字列として返します。
...式の文字列を返します。
#<Method: klass1(klass2)#method> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジュール名です。
klass2......ッドを定義しているクラス/モジュール名、
method は、メソッド名を表します。
//emlist[例][ruby]{
module Foo
def foo
"foo"
end
end
class Bar
include Foo
def bar
end
end
p Bar.new.method(:foo) # => #<Method: Bar(Foo)#foo>
p Bar.new.method(:bar)......ーバ、
klass2 は実際にそのメソッドを定義しているオブジェクトになります。
//emlist[例][ruby]{
# オブジェクトの特異メソッド
obj = ""
class <<obj
def foo
end
end
p obj.method(:foo) # => #<Method: "".foo>
# クラスメソッド(クラスの特異......式の文字列を返します。
#<Method: klass1(klass2)#method(arg) foo.rb:2> (形式1)
klass1 は、Method#inspect では、レシーバのクラス名、
UnboundMethod#inspect では、UnboundMethod オブジェクトの生成
元となったクラス/モジュール名です。
klass......arg は引数を表します。
「foo.rb:2」は Method#source_location を表します。
source_location が nil の場合には付きません。
//emlist[例][ruby]{
module Foo
def foo
"foo"
end
end
class Bar
include Foo
def bar(a, b)
end
end
p Bar.new.method(:foo) # =>......ーバ、
klass2 は実際にそのメソッドを定義しているオブジェクトになります。
//emlist[例][ruby]{
# オブジェクトの特異メソッド
obj = ""
class <<obj
def foo
end
end
p obj.method(:foo) # => #<Method: "".foo() foo.rb:4>
# クラスメソッド(クラ... -
REXML
:: Formatters :: Transitive (12006.0) -
XMLドキュメントをテキストの内容を変えずに 多少の整形を加えて出力するクラスです。
...。
//emlist[][ruby]{
require 'rexml/document'
require 'rexml/formatters/transitive'
doc = REXML::Document.new <<EOS
<root><children>
<grandchildren foo='bar' />
</children></root>
EOS
transitive_formatter = REXML::Formatters::Transitive.new
output = StringIO.new
transitive_formatter.write(doc, ou......tring
# => "<root\n><children\n >\n<grandchildren foo='bar'\n />\n</children\n ></root\n>\n"
print output.string
# >> <root
# >> ><children
# >> >
# >> <grandchildren foo='bar'
# >> />
# >> </children
# >> ></root
# >> >
output = StringIO.new
transitive_formatter.write(REXML::XPath.fir......st(doc, "/root/children"), output)
output.string
# => "<children\n>\n<grandchildren foo='bar'\n />\n</children\n>"
//}... -
WEBrick
:: HTTPResponse # cookies -> [WEBrick :: Cookie] (9206.0) -
レスポンスの Set-Cookie ヘッダの値を表す WEBrick::Cookie オブジェクトの配列です。 レスポンスに新たに Cookie を加えたい場合はこの配列に WEBrick::Cookie オブジェクトを加えます。
...スの Set-Cookie ヘッダの値を表す WEBrick::Cookie オブジェクトの配列です。
レスポンスに新たに Cookie を加えたい場合はこの配列に WEBrick::Cookie オブジェクトを加えます。
require 'webrick'
res.cookies << WEBrick::Cookie.parse_set_cookie(k)... -
OpenSSL
:: Cipher (9024.0) -
共通鍵暗号のために抽象化されたインターフェースを提供するクラスです。
...は暗号アルゴリズムを指定するため
OpenSSL::Cipher.new で暗号オブジェクトを生成することだけでしょう。
もし、このクラスを直接利用して暗号化する場合は、暗号の鍵や
IV(Initialization Vector)の取り扱いについて正しく理解し......* OpenSSL::Cipher.new や OpenSSL::Cipher::AES256.new
などで暗号オブジェクトを生成する
* OpenSSL::Cipher#encrypt, OpenSSL::Cipher#decrypt で
暗号、復号のいずれをするかを設定する
* OpenSSL::Cipher#key=, OpenSSL::Cipher#iv=,
OpenSSL::Cipher#rando......する
key_iv = OpenSSL::PKCS5.pbkdf2_hmac_sha1(pass, salt, 2000, enc.key_len + enc.iv_len)
key = key_iv[0, enc.key_len]
iv = key_iv[enc.key_len, enc.iv_len]
# 鍵とIVを設定する
enc.key = key
enc.iv = iv
# 暗号化する
encrypted_data = ""
encrypted_data << enc.update(da... -
OpenSSL
:: Digest # update(data) -> self (9000.0) -
data でダイジェストオブジェクトの内部状態を更新します。
data でダイジェストオブジェクトの内部状態を更新します。
@param data 入力文字列 -
REXML
:: Document # write(output = $ stdout , indent = -1 , transitive = false , ie _ hack = false , encoding=nil) -> () (6306.0) -
output に XML 文書を出力します。
...引数による引数指定が可能です。
@param output 出力先(IO のように << で書き込めるオブジェクト)
@param indent インデントのスペースの数(-1 だとインデントしない)
@param transitive XMLではインデントのスペースでDOMが変化してしま......に真を渡すと、XMLのDOMに余計な要素が加わらないように
空白の出力を適当に抑制するようになる
@param ie_hack IEはバージョンによってはXMLをちゃんと解釈できないので、
それに対応したXMLを出力するかどうかを真... -
REXML
:: Document # write(output: $ stdout , indent: -1 , transitive: false , ie _ hack: false , encoding: nil) -> () (6306.0) -
output に XML 文書を出力します。
...引数による引数指定が可能です。
@param output 出力先(IO のように << で書き込めるオブジェクト)
@param indent インデントのスペースの数(-1 だとインデントしない)
@param transitive XMLではインデントのスペースでDOMが変化してしま......に真を渡すと、XMLのDOMに余計な要素が加わらないように
空白の出力を適当に抑制するようになる
@param ie_hack IEはバージョンによってはXMLをちゃんと解釈できないので、
それに対応したXMLを出力するかどうかを真...