1272件ヒット
[1-100件を表示]
(0.094秒)
別のキーワード
ライブラリ
- ビルトイン (288)
- csv (24)
- mkmf (12)
-
net
/ http (480) - optparse (36)
-
rake
/ packagetask (96) -
rexml
/ document (228) - socket (24)
- stringio (48)
- strscan (36)
クラス
-
ARGF
. class (60) - Addrinfo (24)
- Binding (48)
- CSV (24)
- Exception (24)
- Module (24)
-
Net
:: HTTP (132) -
Net
:: HTTPGenericRequest (36) -
Net
:: HTTPResponse (96) - Object (48)
- OptionParser (24)
-
REXML
:: Attribute (36) -
REXML
:: Attributes (144) -
REXML
:: Element (36) -
REXML
:: Instruction (12) -
Rake
:: PackageTask (96) - String (12)
- StringIO (48)
- StringScanner (36)
- Thread (24)
- Time (48)
モジュール
- Kernel (12)
-
Net
:: HTTPExceptions (12) -
Net
:: HTTPHeader (204) -
OptionParser
:: Arguable (12)
キーワード
- == (12)
- [] (36)
- []= (12)
-
add
_ field (12) - attribute (12)
-
backtrace
_ locations (12) -
basic
_ auth (12) - body (12)
-
class
_ variable _ get (12) - code (12)
-
connect
_ from (24) -
const
_ get (12) -
content
_ length (12) -
content
_ range (12) -
create
_ makefile (12) - delete (24)
-
delete
_ all (12) - each (12)
-
each
_ attribute (12) -
each
_ capitalized _ name (12) - entity (12)
- eval (12)
- fetch (36)
- get2 (24)
-
get
_ attribute (12) -
get
_ attribute _ ns (12) -
get
_ byte (12) -
get
_ fields (12) -
get
_ text (12) - getbyte (48)
- getc (24)
- getch (12)
- getgm (12)
- getlocal (24)
- getopts (36)
- gets (48)
- getutc (12)
- head2 (24)
-
http
_ version (12) -
instance
_ variable _ defined? (12) -
instance
_ variable _ get (12) -
instance
_ variable _ set (12) -
instance
_ variables (12) - length (12)
-
local
_ variable _ defined? (12) -
local
_ variable _ get (12) -
local
_ variable _ set (12) -
main
_ type (12) - method (24)
- msg (12)
- name (12)
- namespace (12)
- namespaces (12)
-
need
_ zip (12) -
need
_ zip= (12) -
package
_ dir (12) -
package
_ dir= (12) -
package
_ dir _ path (12) -
package
_ files (12) -
package
_ files= (12) - path (12)
- prefix (12)
- prefixes (12)
-
proxy
_ basic _ auth (12) - range (12)
-
range
_ length (12) -
read
_ body (12) - readline (12)
-
request
_ get (24) -
request
_ head (24) - response (12)
-
response
_ body _ permitted? (12) -
send
_ request (12) - shift (12)
- size (12)
-
sub
_ type (12) - target (12)
- text (12)
-
thread
_ variable _ set (12) -
to
_ string (12) - ungetc (12)
- value (12)
検索結果
先頭5件
- Net
:: HTTP # get(path , header = nil , dest = nil) -> Net :: HTTPResponse - Net
:: HTTP # get(path , header = nil , dest = nil) {|body _ segment| . . . . } -> Net :: HTTPResponse - REXML
:: Attributes # get _ attribute _ ns(namespace , name) -> REXML :: Attribute | nil - REXML
:: Attributes # get _ attribute(name) -> Attribute | nil - Binding
# local _ variable _ get(symbol) -> object
-
Net
:: HTTP # get(path , header = nil , dest = nil) -> Net :: HTTPResponse (18345.0) -
サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。
...サーバ上の path にあるエンティティを取得し、
Net::HTTPResponse のインスタンスとして返します。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という......//emlist[例][ruby]{
# net/http version 1.1
response, body = http.get( '/index.html' )
# net/http version 1.2
response = http.get('/index.html')
# compatible in both version
response , = http.get('/index.html')
response.body
# compatible, using block
File.open('save.txt', 'w') {|f|
http.get('/~......foo/', nil) do |str|
f.write str
end
}
//}
@see Net::HTTP#request_get... -
Net
:: HTTP # get(path , header = nil , dest = nil) {|body _ segment| . . . . } -> Net :: HTTPResponse (18345.0) -
サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。
...サーバ上の path にあるエンティティを取得し、
Net::HTTPResponse のインスタンスとして返します。
header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という......//emlist[例][ruby]{
# net/http version 1.1
response, body = http.get( '/index.html' )
# net/http version 1.2
response = http.get('/index.html')
# compatible in both version
response , = http.get('/index.html')
response.body
# compatible, using block
File.open('save.txt', 'w') {|f|
http.get('/~......foo/', nil) do |str|
f.write str
end
}
//}
@see Net::HTTP#request_get... -
REXML
:: Attributes # get _ attribute _ ns(namespace , name) -> REXML :: Attribute | nil (15344.0) -
namespace と name で特定される属性を返します。
...る属性を返します。
namespace で名前空間を、 name で prefix を含まない属性名を
指定します。
指定された属性が存在しない場合は nil を返します。
XML プロセッサが prefix を置き換えてしまった場合でも、このメソッドを
使......URI, 文字列)
@param name 属性名(文字列)
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<-EOS)
<root xmlns:foo="http://example.org/foo"
xmlns:bar="http://example.org/bar">
<a foo:att='1' bar:att='2' att='<'/>
</root>
EOS
a = doc.get_elements("/root/a").fir......st
a.attributes.get_attribute_ns("", "att") # => att='<'
a.attributes.get_attribute_ns("http://example.org/foo", "att") # => foo:att='1'
a.attributes.get_attribute_ns("http://example.org/baz", "att") # => nil
a.attributes.get_attribute_ns("http://example.org/foo", "attt") # => nil
//}... -
REXML
:: Attributes # get _ attribute(name) -> Attribute | nil (15332.0) -
name という名前の属性を取得します。
...う名前の属性を取得します。
name という名前を持つ属性がない場合は nil を返します。
@param name 属性名(文字列)
@see REXML::Attributes#[]
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new(<<-EOS)
<root xmlns:foo="http://example.org/foo"......xmlns:bar="http://example.org/bar">
<a foo:att='1' bar:att='2' att='<'/>
</root>
EOS
a = doc.get_elements("/root/a").first
a.attributes.get_attribute("att") # => att='<'
a.attributes.get_attribute("foo:att") # => foo:att='1'
//}... -
Binding
# local _ variable _ get(symbol) -> object (15238.0) -
引数 symbol で指定した名前のローカル変数に設定された値を返します。
...オブジェクトで指定します。
@raise NameError 引数 symbol で指定したローカル変数が未定義の場合に発生します。
//emlist[例][ruby]{
def foo
a = 1
binding.local_variable_get(:a) # => 1
binding.local_variable_get(:b) # => NameError
end
//}
このメソッ......ドは以下のコードの短縮形です。
//emlist[][ruby]{
binding.eval("#{symbol}")
//}
@see Binding#local_variable_set, Binding#local_variable_defined?... -
Object
# instance _ variable _ get(var) -> object | nil (12232.0) -
オブジェクトのインスタンス変数の値を取得して返します。
...ば nil を返します。
@param var インスタンス変数名を文字列か Symbol で指定します。
//emlist[][ruby]{
class Foo
def initialize
@foo = 1
end
end
obj = Foo.new
p obj.instance_variable_get("@foo") #=> 1
p obj.instance_variable_get(:@foo) #=> 1
p obj.instanc......e_variable_get(:@bar) #=> nil
//}
@see Object#instance_variable_set,Object#instance_variables,Object#instance_variable_defined?... -
Net
:: HTTPHeader # get _ fields(key) -> [String] (12226.0) -
key ヘッダフィールドの値 (文字列) を配列で返します。
...ール名を文字列で与えます。
//emlist[例][ruby]{
require 'net/http'
uri = URI.parse('http://www.example.com/index.html')
res = Net::HTTP.get_response(uri)
res.get_fields('accept-ranges') # => ["none"]
//}
@see Net::HTTPHeader#[] , Net::HTTPHeader#[]=,
Net::HTTPHeader#add_field... -
Module
# class _ variable _ get(name) -> object (12220.0) -
クラス/モジュールに定義されているクラス変数 name の値を返します。
...の値を返します。
@param name String または Symbol を指定します。
@raise NameError クラス変数 name が定義されていない場合、発生します。
//emlist[例][ruby]{
class Fred
@@foo = 99
end
def Fred.foo
class_variable_get(:@@foo)
end
p Fred.foo #=> 99
//}... -
Object
# instance _ variable _ defined?(var) -> bool (12219.0) -
インスタンス変数 var が定義されていたら真を返します。
...list[][ruby]{
class Fred
def initialize(p1, p2)
@a, @b = p1, p2
end
end
fred = Fred.new('cat', 99)
p fred.instance_variable_defined?(:@a) #=> true
p fred.instance_variable_defined?("@b") #=> true
p fred.instance_variable_defined?("@c") #=> false
//}
@see Object#instance_variable_get,......Object#instance_variable_set,Object#instance_variables...