383件ヒット
[1-100件を表示]
(0.144秒)
別のキーワード
ライブラリ
- ビルトイン (75)
-
irb
/ cmd / help (11) - json (11)
- rake (66)
-
rexml
/ document (198) -
rubygems
/ commands / update _ command (11) -
rubygems
/ specification (11)
クラス
-
Gem
:: Commands :: UpdateCommand (11) -
Gem
:: Specification (11) -
IRB
:: ExtendCommand :: Help (11) - Module (64)
-
REXML
:: Attribute (11) -
REXML
:: Attributes (22) -
REXML
:: DocType (11) -
REXML
:: Element (66) -
Rake
:: NameSpace (22) -
Rake
:: TaskArguments (11) - Regexp (11)
モジュール
- Kernel (33)
-
REXML
:: Namespace (88) -
Rake
:: TaskManager (11)
キーワード
- JSON (11)
- [] (11)
-
add
_ namespace (22) - attribute (11)
-
delete
_ namespace (11) - execute (11)
-
get
_ attribute _ ns (11) -
has
_ name? (11) - import (11)
-
in
_ namespace (11) -
local
_ name (11) - name (11)
- name= (11)
- namespace (33)
- namespaces (33)
-
new
_ scope (11) - prefix (11)
- prefix= (11)
- private (16)
-
private
_ class _ method (8) - protected (16)
- public (16)
-
public
_ class _ method (8) - tasks (11)
-
which
_ to _ update (11)
検索結果
先頭5件
-
Regexp
# names -> [String] (21120.0) -
正規表現に含まれる名前付きキャプチャ(named capture)の名前を 文字列の配列で返します。
...正規表現に含まれる名前付きキャプチャ(named capture)の名前を
文字列の配列で返します。
//emlist[例][ruby]{
/(?<foo>.)(?<bar>.)(?<baz>.)/.names
# => ["foo", "bar", "baz"]
/(?<foo>.)(?<foo>.)/.names
# => ["foo"]
/(.)(.)/.names
# => []
//}... -
Kernel
# namespace(name = nil) { . . . } -> Rake :: NameSpace (12401.0) -
新しい名前空間を作成します。
...新しい名前空間を作成します。
与えられたブロックを評価する間は、その名前空間を使用します。
例:
ns = namespace "nested" do
task :run
end
task_run = ns[:run] # find :run in the given namespace.
@see Rake::TaskManager#in_namespace... -
REXML
:: Element # delete _ namespace(namespace = "xmlns") -> self (12401.0) -
名前空間を要素から削除します。
...間を削除します。
@param namespace 削除する名前空間の prefix
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new "<a xmlns:foo='bar' xmlns='twiddle'/>"
doc.root.delete_namespace
doc.to_s # => "<a xmlns:foo='bar'/>"
doc.root.delete_namespace 'foo'
doc.to_s # => "<a/... -
Rake
:: TaskManager # in _ namespace(name) {|name _ space| . . . } -> Array (12301.0) -
与えられた名前の名前空間でブロックを評価します。
...クを評価します。
@param name 名前を指定します。
//emlist[][ruby]{
# Rakefile での記載例とする
task default: :test_rake_app
namespace :sample do
def hoge
puts "hoge"
end
end
task :test_rake_app do
task.application.in_namespace("sample") do
hoge # => "hoge"... -
REXML
:: Attribute # namespace(arg = nil) -> String | nil (12213.0) -
属性の名前空間の URI を返します。
...@param arg この値を指定すると、その属性の名前空間でなく、arg という名前空間
の URI が返されます。
通常は省略します。
//emlist[][ruby]{
require 'rexml/document'
e = REXML::Element.new("el")
e.add_attribute("xmlns:ns", "http://www.example.......com/ns")
e.add_attribute("ns:r", "rval")
p e.attributes.get_attribute("r").prefix # => "ns"
p e.attributes.get_attribute("r").namespace # => "http://www.example.com/ns"
//}... -
REXML
:: Attributes # namespaces -> { String => String } (12213.0) -
self の中で宣言されている名前空間の集合を返します。
...します。
返り値は名前空間の prefix をキーとし、URI を値とする
Hash を返します。
//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
p doc.root.attributes.namespaces
# => {"foo"=>"http://example.org/foo", "bar"=>"http://example.org/bar"}
p a.attributes.namespaces
# => {}
//}... -
REXML
:: DocType # namespaces -> nil (12201.0) -
nil を返します。
nil を返します。 -
REXML
:: Element # add _ namespace(prefix , uri) -> self (12201.0) -
名前空間を要素に追加します。
...。
引数が2個の場合は prefix と uri を指定します。
引数が1個の場合はデフォルトの namespace の uri を指定します。
既に同じ prefix が存在する場合はそれが上書きされます。
@param prefix 名前空間の prefix
@param uri 名前空間の uri......by]{
require 'rexml/document'
a = REXML::Element.new("a")
a.add_namespace("xmlns:foo", "bar" )
a.add_namespace("foo", "bar") # 上と同じ意味
a.add_namespace("twiddle")
a.to_s # => "<a xmlns:foo='bar' xmlns='twiddle'/>"
a.add_namespace("foo", "baz")
a.to_s # => "<a xmlns:foo='baz' xmlns='twiddl... -
REXML
:: Element # add _ namespace(uri) (12201.0) -
名前空間を要素に追加します。
...。
引数が2個の場合は prefix と uri を指定します。
引数が1個の場合はデフォルトの namespace の uri を指定します。
既に同じ prefix が存在する場合はそれが上書きされます。
@param prefix 名前空間の prefix
@param uri 名前空間の uri......by]{
require 'rexml/document'
a = REXML::Element.new("a")
a.add_namespace("xmlns:foo", "bar" )
a.add_namespace("foo", "bar") # 上と同じ意味
a.add_namespace("twiddle")
a.to_s # => "<a xmlns:foo='bar' xmlns='twiddle'/>"
a.add_namespace("foo", "baz")
a.to_s # => "<a xmlns:foo='baz' xmlns='twiddl... -
REXML
:: Element # namespace(prefix=nil) -> String (12201.0) -
self の文脈で prefix が指している名前空間の URI を返します。
...self の文脈で prefix が指している名前空間の URI を返します。
prefix を省略すると、デフォルトの名前空間の URI を返します。
prefix で指示される名前空間の宣言が存在しない場合は nil を返します。
//emlist[][ruby]{
require 'rexml/......document'
doc = REXML::Document.new("<a xmlns='1' xmlns:y='2'><b/><c xmlns:z='3'/><y:d /></a>")
b = doc.elements['//b']
b.namespace # => "1"
b.namespace("y") # => "2"
b.namespace("z") # => nil
d = doc.elements['//y:d']
d.namespace # => "2"
//}...