55件ヒット
[1-55件を表示]
(0.096秒)
ライブラリ
-
rdoc
/ context (11) -
rexml
/ document (33) - win32ole (11)
クラス
-
RDoc
:: Context (11) -
REXML
:: Attributes (22) -
REXML
:: Element (11) -
WIN32OLE
_ TYPE (11)
キーワード
-
default
_ event _ sources (11) -
each
_ attribute (22) -
each
_ element _ with _ attribute (11)
検索結果
先頭5件
- REXML
:: Attributes # each _ attribute {|attribute| . . . } -> () - REXML
:: Attributes # each {|name , value| . . . } -> () - RDoc
:: Context # each _ attribute {|a| . . . } -> [RDoc :: Attr] - REXML
:: Element # each _ element _ with _ attribute(key , value = nil , max = 0 , name = nil) {|element| . . . } -> () - WIN32OLE
_ TYPE # default _ event _ sources -> [WIN32OLE _ TYPE]
-
REXML
:: Attributes # each _ attribute {|attribute| . . . } -> () (24638.0) -
各属性に対しブロックを呼び出します。
...の属性は REXML::Attribute オブジェクトで渡されます。
//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_ele......ments("/root/a").first
a.attributes.each_attribute do |attr|
p [attr.namespace, attr.name, attr.value]
end
# => ["http://example.org/foo", "att", "1"]
# => ["http://example.org/bar", "att", "2"]
# => ["", "att", "<"]
//}... -
REXML
:: Attributes # each {|name , value| . . . } -> () (24314.0) -
各属性の名前と値に対しブロックを呼び出します。
...t[][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.each do |name, value|
p [name, value]
e......nd
# => ["foo:att", "1"]
# => ["bar:att", "2"]
# => ["att", "<"]
//}... -
RDoc
:: Context # each _ attribute {|a| . . . } -> [RDoc :: Attr] (18519.0) -
追加された RDoc::Attr に対してブロックを評価します。
...追加された RDoc::Attr に対してブロックを評価します。... -
REXML
:: Element # each _ element _ with _ attribute(key , value = nil , max = 0 , name = nil) {|element| . . . } -> () (18426.0) -
特定の属性を持つすべての子要素を引数としてブロックを呼び出します。
...呼び出します。
key で指定した属性名の属性を持つ要素のみを対象とします。
value を指定すると、keyで指定した属性名を持つ属性の値がvalueである
もののみを対象とします。
maxを指定すると、対象となる子要素の先頭 max......lue 属性値(文字列)
@param max ブロック呼出の対象とする子要素の最大個数
@param name xpath文字列
//emlist[][ruby]{
require 'rexml/document'
doc = REXML::Document.new("<a><b id='1'/><c id='2'/><d id='1'/><e/></a>")
doc.root.each_element_with_attribute('id'){|e| p e }
# >>......d='1'/>
# >> <c id='2'/>
# >> <d id='1'/>
doc.root.each_element_with_attribute('id', '1'){|e| p e }
# >> <b id='1'/>
# >> <d id='1'/>
doc.root.each_element_with_attribute('id', '1', 1){|e| p e }
# >> <b id='1'/>
doc.root.each_element_with_attribute('id', '1', 0, 'd'){|e| p e }
# >> <d id='1'/>
//}... -
WIN32OLE
_ TYPE # default _ event _ sources -> [WIN32OLE _ TYPE] (6213.0) -
型が持つソースインターフェイスを取得します。
...す。
default_event_sourcesメソッドは、selfがCoClass(コンポーネントクラス)
の場合、そのクラスがサポートするデフォルトのソースインターフェイス(イ
ベントの通知元となるインターフェイス)を返します。
@return デフォ......合は空配列を返します。
tobj = WIN32OLE_TYPE.new('Microsoft Excel 14.0 Object Library', 'Worksheet')
tobj.default_event_sources.map {|intf| intf.name} #=> ["DocEvents"]
WIN32OLE_EVENT.newでインターフェイス名を指定しない場合は、ここで
返されたインター......ベントのStatusTextChangeイベントのメッセージについては既
知としています。
# coding : cp932
require 'win32ole'
type = WIN32OLE_TYPE.new('Microsoft Internet Controls', 'InternetExplorer')
ctl = WIN32OLE.new(type.progid)
source = type.default_event_sources[0]
class...