Class: TurboRex::Windows::COM::Interface
- Inherits:
-
Object
- Object
- TurboRex::Windows::COM::Interface
- Includes:
- WellKnownIID
- Defined in:
- lib/turborex/windows/com/interface.rb
Direct Known Subclasses
IClassFactory, IPSFactoryBuffer, IRpcProxyBuffer, IRpcStubBuffer, IStorage, IStream, IUnknown
Defined Under Namespace
Classes: IClassFactory, IPSFactoryBuffer, IRpcProxyBuffer, IRpcStubBuffer, IStorage, IStream, IUnknown
Constant Summary
Constants included from WellKnownIID
WellKnownIID::IID_IClassFactory, WellKnownIID::IID_IPSFactoryBuffer, WellKnownIID::IID_IRpcProxyBuffer, WellKnownIID::IID_IRpcStubBuffer, WellKnownIID::IID_IStorage, WellKnownIID::IID_IStream, WellKnownIID::IID_IUnknown
Instance Attribute Summary collapse
-
#iid ⇒ Object
readonly
Returns the value of attribute iid.
-
#methods ⇒ Object
readonly
Returns the value of attribute methods.
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
-
#pvtbl ⇒ Object
readonly
Returns the value of attribute pvtbl.
-
#this ⇒ Object
Returns the value of attribute this.
-
#vtbl ⇒ Object
readonly
Returns the value of attribute vtbl.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(iid, methods, parent = IUnknown) ⇒ Interface
constructor
A new instance of Interface.
- #marshal_to_string(mshctx = MSHCTX_DIFFERENTMACHINE, mshlflags = MSHLFLAGS_NORMAL) ⇒ Object
- #name ⇒ Object
Constructor Details
#initialize(iid, methods, parent = IUnknown) ⇒ Interface
Returns a new instance of Interface.
469 470 471 472 473 474 475 476 477 |
# File 'lib/turborex/windows/com/interface.rb', line 469 def initialize(iid, methods, parent=IUnknown) @iid = iid @methods = methods @parent = parent @api_proxy = Win32API.dup @methods.freeze definie_rb_proxy end |
Instance Attribute Details
#iid ⇒ Object (readonly)
Returns the value of attribute iid.
8 9 10 |
# File 'lib/turborex/windows/com/interface.rb', line 8 def iid @iid end |
#methods ⇒ Object (readonly)
Returns the value of attribute methods.
12 13 14 |
# File 'lib/turborex/windows/com/interface.rb', line 12 def methods @methods end |
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
11 12 13 |
# File 'lib/turborex/windows/com/interface.rb', line 11 def parent @parent end |
#pvtbl ⇒ Object (readonly)
Returns the value of attribute pvtbl.
10 11 12 |
# File 'lib/turborex/windows/com/interface.rb', line 10 def pvtbl @pvtbl end |
#this ⇒ Object
Returns the value of attribute this.
7 8 9 |
# File 'lib/turborex/windows/com/interface.rb', line 7 def this @this end |
#vtbl ⇒ Object (readonly)
Returns the value of attribute vtbl.
9 10 11 |
# File 'lib/turborex/windows/com/interface.rb', line 9 def vtbl @vtbl end |
Class Method Details
.define_interface(iid, method_defs = {}, parent = IUnknown) ⇒ Object
496 497 498 499 500 501 502 503 504 |
# File 'lib/turborex/windows/com/interface.rb', line 496 def self.define_interface(iid, method_defs={}, parent=IUnknown) api_proxy = Win32API.dup methods = [*parent::METHODS] method_defs.each_value {|v| api_proxy.parse_c(v) } method_defs.each_key {|k| methods<<api_proxy.cp.toplevel.symbol[k.to_s]} methods.compact! new(iid, methods, parent) end |
Instance Method Details
#marshal_to_string(mshctx = MSHCTX_DIFFERENTMACHINE, mshlflags = MSHLFLAGS_NORMAL) ⇒ Object
492 493 494 |
# File 'lib/turborex/windows/com/interface.rb', line 492 def marshal_to_string(mshctx=MSHCTX_DIFFERENTMACHINE, mshlflags=MSHLFLAGS_NORMAL) Utils.marshal_interface_to_string(self, mshctx, mshlflags) end |
#name ⇒ Object
506 507 508 |
# File 'lib/turborex/windows/com/interface.rb', line 506 def name self.class.to_s end |