Class: WIN32OLE_METHOD
- Inherits:
-
Object
- Object
- WIN32OLE_METHOD
- Defined in:
- win32ole.c,
win32ole.c
Overview
WIN32OLE_METHOD objects represent OLE method information.
Instance Method Summary collapse
-
#dispid ⇒ Object
Returns dispatch ID.
-
#event? ⇒ Boolean
Returns true if the method is event.
-
#event_interface ⇒ Object
Returns event interface name if the method is event.
-
#helpcontext ⇒ Object
Returns help context.
-
#helpfile ⇒ Object
Returns help file.
-
#helpstring ⇒ Object
Returns help string of OLE method.
-
#new(ole_type, method) ⇒ WIN32OLE_METHOD object
constructor
Returns a new WIN32OLE_METHOD object which represents the information about OLE method.
-
#invkind ⇒ Object
Returns the method invoke kind.
-
#invoke_kind ⇒ Object
Returns the method kind string.
-
#name ⇒ Object
(also: #to_s)
call-seq WIN32OLE_METHOD#name.
-
#offset_vtbl ⇒ Object
Returns the offset ov VTBL.
-
#params ⇒ Object
returns array of WIN32OLE_PARAM object corresponding with method parameters.
-
#return_type ⇒ Object
Returns string of return value type of method.
-
#return_type_detail ⇒ Object
Returns detail information of return value type of method.
-
#return_vtype ⇒ Object
Returns number of return value type of method.
-
#size_opt_params ⇒ Object
Returns the size of optional parameters.
-
#size_params ⇒ Object
Returns the size of arguments of the method.
-
#visible? ⇒ Boolean
Returns true if the method is public.
Constructor Details
#new(ole_type, method) ⇒ WIN32OLE_METHOD object
Returns a new WIN32OLE_METHOD object which represents the information about OLE method. The first argument ole_type specifies WIN32OLE_TYPE object. The second argument method specifies OLE method name defined OLE class which represents WIN32OLE_TYPE object.
tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook')
method = WIN32OLE_METHOD.new(tobj, 'SaveAs')
4365 4366 4367 |
# File 'win32ole.c', line 4365 static VALUE folemethod_initialize(self, oletype, method) VALUE self; |
Instance Method Details
#dispid ⇒ Object
Returns dispatch ID. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.dispid # => 181
4895 4896 4897 |
# File 'win32ole.c', line 4895 static VALUE folemethod_dispid(self) VALUE self; |
#event? ⇒ Boolean
Returns true if the method is event. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SheetActivate') puts method.event? # => true
4710 4711 4712 |
# File 'win32ole.c', line 4710 static VALUE folemethod_event(self) VALUE self; |
#event_interface ⇒ Object
Returns event interface name if the method is event. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SheetActivate') puts method.event_interface # => WorkbookEvents
4732 4733 4734 |
# File 'win32ole.c', line 4732 static VALUE folemethod_event_interface(self) VALUE self; |
#helpcontext ⇒ Object
Returns help context. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.helpcontext # => 65717
4861 4862 4863 |
# File 'win32ole.c', line 4861 static VALUE folemethod_helpcontext(self) VALUE self; |
#helpfile ⇒ Object
Returns help file. If help file is not found, then the method returns nil. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.helpfile # => C:...VBAXL9.CHM
4828 4829 4830 |
# File 'win32ole.c', line 4828 static VALUE folemethod_helpfile(self) VALUE self; |
#helpstring ⇒ Object
Returns help string of OLE method. If the help string is not found, then the method returns nil. tobj = WIN32OLE_TYPE.new('Microsoft Internet Controls', 'IWebBrowser') method = WIN32OLE_METHOD.new(tobj, 'Navigate') puts method.helpstring # => Navigates to a URL or file.
4795 4796 4797 |
# File 'win32ole.c', line 4795 static VALUE folemethod_helpstring(self) VALUE self; |
#invkind ⇒ Object
Returns the method invoke kind. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.invkind # => 1
4565 4566 4567 |
# File 'win32ole.c', line 4565 static VALUE folemethod_invkind(self) VALUE self; |
#invoke_kind ⇒ Object
Returns the method kind string. The string is "UNKNOWN" or "PROPERTY" or "PROPERTY" or "PROPERTYGET" or "PROPERTYPUT" or "PROPERTYPPUTREF" or "FUNC". tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.invoke_kind # => "FUNC"
4585 4586 4587 |
# File 'win32ole.c', line 4585 static VALUE folemethod_invoke_kind(self) VALUE self; |
#name ⇒ Object Also known as: to_s
call-seq WIN32OLE_METHOD#name
Returns the name of the method.
tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook')
method = WIN32OLE_METHOD.new(tobj, 'SaveAs')
puts method.name # => SaveAs
4399 4400 4401 |
# File 'win32ole.c', line 4399 static VALUE folemethod_name(self) VALUE self; |
#offset_vtbl ⇒ Object
Returns the offset ov VTBL. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.offset_vtbl # => 40
4929 4930 4931 |
# File 'win32ole.c', line 4929 static VALUE folemethod_offset_vtbl(self) VALUE self; |
#params ⇒ Object
returns array of WIN32OLE_PARAM object corresponding with method parameters. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SaveAs') p method.params # => [Filename, FileFormat, Password, WriteResPassword, ReadOnlyRecommended, CreateBackup, AccessMode, ConflictResolution, AddToMru, TextCodepage, TextVisualLayout]
5061 5062 5063 |
# File 'win32ole.c', line 5061 static VALUE folemethod_params(self) VALUE self; |
#return_type ⇒ Object
Returns string of return value type of method. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.return_type # => Workbook
4434 4435 4436 |
# File 'win32ole.c', line 4434 static VALUE folemethod_return_type(self) VALUE self; |
#return_type_detail ⇒ Object
Returns detail information of return value type of method. The information is array. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') p method.return_type_detail # => ["PTR", "USERDEFINED", "Workbook"]
4508 4509 4510 |
# File 'win32ole.c', line 4508 static VALUE folemethod_return_type_detail(self) VALUE self; |
#return_vtype ⇒ Object
Returns number of return value type of method. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.return_vtype # => 26
4471 4472 4473 |
# File 'win32ole.c', line 4471 static VALUE folemethod_return_vtype(self) VALUE self; |
#size_opt_params ⇒ Object
Returns the size of optional parameters. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SaveAs') puts method.size_opt_params # => 4
4998 4999 5000 |
# File 'win32ole.c', line 4998 static VALUE folemethod_size_opt_params(self) VALUE self; |
#size_params ⇒ Object
Returns the size of arguments of the method. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbook') method = WIN32OLE_METHOD.new(tobj, 'SaveAs') puts method.size_params # => 11
4964 4965 4966 |
# File 'win32ole.c', line 4964 static VALUE folemethod_size_params(self) VALUE self; |
#visible? ⇒ Boolean
Returns true if the method is public. tobj = WIN32OLE_TYPE.new('Microsoft Excel 9.0 Object Library', 'Workbooks') method = WIN32OLE_METHOD.new(tobj, 'Add') puts method.visible? # => true
4625 4626 4627 |
# File 'win32ole.c', line 4625 static VALUE folemethod_visible(self) VALUE self; |