|
Sun Adapter for COM/DCOM API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.stc.connector.comadapter.comruntimeimpl.STCUnknownImpl com.stc.connector.comadapter.comruntimeimpl.STCDispatchDriver
public class STCDispatchDriver
The STCDispatchDriver class wraps several of the calls on the IDispatch interface. It does not wrap the IDispatch per se. Rather, its purpose is to allow you to create an automation-compatible component and access properties on that object and/or invoke methods on it by name.
Where noted, the methods can throw the STCComException.
STCComException
,
STCUnknownImpl
,
STCComVariant
Constructor Summary | |
---|---|
STCDispatchDriver(int handle)
The integer parameter is the COM interface handle from C++. |
Method Summary | |
---|---|
STCComVariant |
getProperty(java.lang.String propertyName,
STCComVariant[] args)
Gets a property by name. |
STCComVariant |
invoke(java.lang.String methodName,
STCComVariant[] args)
This method allows you to call a method by name on the underlying COM interface. |
void |
setProperty(java.lang.String propertyName,
STCComVariant[] args)
Sets a property by name. |
Methods inherited from class com.stc.connector.comadapter.comruntimeimpl.STCUnknownImpl |
---|
AddRef, isValid, Release |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.stc.connector.comadapter.comruntime.STCIUnknown |
---|
AddRef, Release |
Constructor Detail |
---|
public STCDispatchDriver(int handle)
Method Detail |
---|
public STCComVariant invoke(java.lang.String methodName, STCComVariant[] args) throws STCComException
invoke
in interface STCIDispatch
methodName
- The method name. Note that case is significant.args
- An array of STCComVariant. As per COM rules, the
arguments in this array are in reverse order.
STCComException
- if Invoke on the underlying object fails.public void setProperty(java.lang.String propertyName, STCComVariant[] args) throws STCComException
setProperty
in interface STCIDispatch
propertyName
- The name of the property to set. Note that case is
significant.args
- An array of STCComVariant. As per COM rules, the
arguments in this array are in reverse order.
This parameter must be provided all the time since the array
contains at least the new property value.
STCComException
- Thrown if the method on underlying object fails.public STCComVariant getProperty(java.lang.String propertyName, STCComVariant[] args) throws STCComException
getProperty
in interface STCIDispatch
propertyName
- The name of the property to get. Note that case is
significant.args
- An array of STCComVariant. As per COM rules, the
arguments in this array are in reverse order.
This parameter can be null or empty STCComVariant[] when the property
does not have any parameters.
STCComVariant
- Returns an STCComVariant which
holds the resulting value.
STCComException
- Thrown if the method on underlying COM interface fails.
|
Sun Adapter for COM/DCOM API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |