7件ヒット
[1-7件を表示]
(0.040秒)
ライブラリ
- rake (1)
-
rexml
/ document (6)
クラス
-
REXML
:: Attribute (1) -
REXML
:: Attributes (1) -
REXML
:: DocType (1) -
REXML
:: Element (2)
モジュール
- Kernel (1)
-
REXML
:: Namespace (1)
キーワード
- attribute (1)
-
get
_ attribute _ ns (1) -
has
_ name? (1) - namespaces (1)
検索結果
先頭5件
-
Kernel
# namespace(name = nil) { . . . } -> Rake :: NameSpace (54967.0) -
新しい名前空間を作成します。
新しい名前空間を作成します。
与えられたブロックを評価する間は、その名前空間を使用します。
例:
ns = namespace "nested" do
task :run
end
task_run = ns[:run] # find :run in the given namespace.
@see Rake::TaskManager#in_namespace -
REXML
:: Attribute # namespace(arg = nil) -> String | nil (54949.0) -
属性の名前空間の URI を返します。
属性の名前空間の URI を返します。
URI が定義されていない場合は nil を返します。
@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.... -
REXML
:: Element # namespace(prefix=nil) -> String (54718.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"
... -
REXML
:: DocType # namespaces -> nil (18655.0) -
nil を返します。
nil を返します。 -
REXML
:: Namespace # has _ name?(other , ns = nil) -> bool (9361.0) -
self が other と ns で指定した名前を持っているならば真を返します。
self が other と ns で指定した名前を持っているならば真を返します。
ns が nil でない場合は名前空間も比較されます。
other が ":" を含んでいる(つまり prefix を含んでいる)場合は
REXML::Namespace#fully_expanded_name と other を比較します。
どちらでもない場合は other と REXML::Namespace#name を直接
比較します。
@param other 比較する名前(文字列)
@param ns 比較する名前空間(文字列) -
REXML
:: Element # attribute(name , namespace = nil) -> REXML :: Attribute | nil (985.0) -
name で指定される属性を返します。
name で指定される属性を返します。
属性は REXML::Attribute オブジェクトの形で返します。
name は "foo:bar" のように prefix を指定することができます。
namespace で名前空間の URI を指定することで、その名前空間内で
name という属性名を持つ属性を指定できます。
指定した属性名の属性がない場合は nil を返します。
@param name 属性名(文字列)
@param namespace 名前空間のURI(文字列)
//emlist[][ruby]{
require 'rexml/document'
doc = R... -
REXML
:: Attributes # get _ attribute _ ns(namespace , name) -> REXML :: Attribute | nil (748.0) -
namespace と name で特定される属性を返します。
namespace と name で特定される属性を返します。
namespace で名前空間を、 name で prefix を含まない属性名を
指定します。
指定された属性が存在しない場合は nil を返します。
XML プロセッサが prefix を置き換えてしまった場合でも、このメソッドを
使うことで属性を正しく指定することができます。
@param namespace 名前空間(URI, 文字列)
@param name 属性名(文字列)
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.ne...