るりまサーチ

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

別のキーワード

  1. _builtin path
  2. pathname to_path
  3. _builtin absolute_path
  4. _builtin to_path
  5. file path

検索結果

<< 1 2 3 ... > >>

Net::HTTP#get(path, header = nil, dest = nil) -> Net::HTTPResponse (18256.0)

サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。

...サーバ上の path にあるエンティティを取得し、
Net::HTTPResponse のインスタンスとして返します。

header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という...
...さい。
dest を指定した場合には
ボディを少しずつ取得して順次
「dest << ボディの断片」を実行します。

@param path 取得するエンティティのパスを文字列で指定します。
@param header リクエストの 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.writ...

Net::HTTP#get(path, header = nil, dest = nil) {|body_segment| .... } -> Net::HTTPResponse (18256.0)

サーバ上の path にあるエンティティを取得し、 Net::HTTPResponse のインスタンスとして返します。

...サーバ上の path にあるエンティティを取得し、
Net::HTTPResponse のインスタンスとして返します。

header が nil
でなければ、リクエストを送るときにその内容を HTTP ヘッダとして
送ります。 header は { 'Accept' = > '*/*', ... } という...
...さい。
dest を指定した場合には
ボディを少しずつ取得して順次
「dest << ボディの断片」を実行します。

@param path 取得するエンティティのパスを文字列で指定します。
@param header リクエストの 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.writ...

Net::HTTP.get(host, path, port = 80) -> String (18237.0)

指定した対象に GET リクエストを送り、そのボディを 文字列として返します。

...指定した対象に GET リクエストを送り、そのボディを
文字列として返します。

対象の指定方法は URI で指定するか、
(host, path, port) で指定するかのいずれかです。

@param uri データの取得対象を URI で指定します。
@param host...
...接続先のホストを文字列で指定します。
@param path データの存在するパスを文字列で指定します。
@param port 接続するポートを整数で指定します。
@see Net::HTTP#get...

Net::HTTP.get(uri) -> String (18137.0)

指定した対象に GET リクエストを送り、そのボディを 文字列として返します。

...指定した対象に GET リクエストを送り、そのボディを
文字列として返します。

対象の指定方法は URI で指定するか、
(host, path, port) で指定するかのいずれかです。

@param uri データの取得対象を URI で指定します。
@param host...
...接続先のホストを文字列で指定します。
@param path データの存在するパスを文字列で指定します。
@param port 接続するポートを整数で指定します。
@see Net::HTTP#get...

Net::HTTPGenericRequest#path -> String (18129.0)

リクエストする path を文字列で返します。

...リクエストする path を文字列で返します。

//emlist[例][ruby]{
require 'net/http'

uri = URI.parse('http://www.example.com/index.html')
req = Net::HTTP::Get.new(uri.request_uri)
req.path # => "/index.html"
//}...

絞り込み条件を変える

Win32::Resolv.#get_hosts_path -> String | nil (12214.0)

hosts ファイルのパスを返します。ファイルが存在しない場合は nil を返します。

...hosts ファイルのパスを返します。ファイルが存在しない場合は nil を返します。

例:

require "win32/resolv"
p Win32::Resolv.get_hosts_path #=> "C:\Windows\System32\drivers\etc\hosts"...

Gem::Commands::UnpackCommand#get_path(gemname, version_req) -> String | nil (12202.0)

引数で指定された条件にマッチする Gem パッケージを保存しているパスを返します。

引数で指定された条件にマッチする Gem パッケージを保存しているパスを返します。

@param gemname Gem パッケージの名前を指定します。

@param version_req バージョンの満たすべき条件を文字列で指定します。

Gem::RemoteFetcher#get_file_uri_path(uri) -> String (12202.0)

与えられた URI から "file://" を取り除いた文字列を返します。

与えられた URI から "file://" を取り除いた文字列を返します。

@param uri URI を表す文字列を指定します。

Pathname.getwd -> Pathname (9200.0)

カレントディレクトリを元に Pathname オブジェクトを生成します。 Pathname.new(Dir.getwd) と同じです。

...カレントディレクトリを元に Pathname オブジェクトを生成します。
Path
name.new(Dir.getwd) と同じです。

//emlist[例][ruby]{
require "pathname"

Path
name.getwd #=> #<Pathname:/home/zzak/projects/ruby>
//}

@see Dir.getwd...

Rake::PackageTask#package_dir_path -> String (9107.0)

パッケージに含むファイルを配置するディレクトリを返します。

...パッケージに含むファイルを配置するディレクトリを返します。

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

Rake::PackageTask.new("sample", "1.0.0") do |package_task|
package_task.package_dir_path # => "pkg/sample-1.0.0"
end
//}...

絞り込み条件を変える

<< 1 2 3 ... > >>