るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.613秒)
トップページ > クエリ:t[x] > クエリ:Ruby[x] > クエリ:ruby[x] > クエリ:Method[x] > クエリ:method[x] > クエリ:eval[x] > クエリ:define_method[x] > クエリ:default_event_sources[x]

別のキーワード

  1. _builtin new
  2. _builtin inspect
  3. _builtin []
  4. _builtin to_s
  5. _builtin each

ライブラリ

クラス

検索結果

WIN32OLE_TYPE#default_event_sources -> [WIN32OLE_TYPE] (27427.0)

型が持つソースインターフェイスを取得します。

...ます。

default_event_sources
メソッドは、selfがCoClass(コンポーネントクラス)
の場合、そのクラスがサポートするデフォルトのソースインターフェイス(イ
ベントの通知元となるインターフェイス)を返します。

@return デフ...
...ole'

t
ype = WIN32OLE_TYPE.new('Microsoft Internet Controls', 'InternetExplorer')
ctl = WIN32OLE.new(type.progid)
source = type.default_event_sources[0]
class WebEvent
def initialize
@completed = false
end
attr_reader :completed
end
source.ole_methods.each do |m|
WebEvent.mod...
..._eval do
define_method
("on#{m.name}") do |*arg|
if arg[0] == "ページが表示されました"
@completed = true
end
puts "#{Time.now}: #{m.name} was called"
p arg
end
end
end
evt = WIN32OLE_EVENT.new(ctl)
evt.handler = WebEvent.new
ctl.navigat...