blob: 30319b55a3f8b3e265753097faecd1f32f92cbeb (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
begin
require 'win32ole.so'
rescue LoadError
# do nothing
end
if defined?(WIN32OLE)
# WIN32OLE
class WIN32OLE
#
# By overriding Object#methods, WIN32OLE might
# work well with did_you_mean gem.
# This is exprimental.
#
# require 'win32ole'
# dict = WIN32OLE.new('Scripting.Dictionary')
# dict.Ade('a', 1)
# #=> Did you mean? Add
#
def methods(*args)
super + ole_methods.map(&:name)
end
end
end
|