OpenCOM
Interface IUnknown
- All Known Subinterfaces:
- IOpenCOM
- All Known Implementing Classes:
- CFMetaInterface, OpenCOM, OpenCOMComponent
public interface IUnknown
The IUnknown interface is a central aspect of OpenCOM. However,
it is not actually required in the Java version. Standard Interface/Object behaviour
in Java negates the need for QueryInterface. Furthermore, the garbage collector
means addref and release are not required. However, IUnknown remains in this
version to present the same (okay similar) programming model to traditional
OpenCOM.
Note: QI is an improvement over object casting, like OpenCOM you can detect if the
interface is available on the component before invoking it. That is, we retain
one of the programming model benefits of COM.
|
Method Summary |
java.lang.Object |
QueryInterface(java.lang.String interfaceName)
Obtain a reference to the interface of the type passed as parameter |
QueryInterface
java.lang.Object QueryInterface(java.lang.String interfaceName)
- Obtain a reference to the interface of the type passed as parameter
- Parameters:
interfaceName - a string representing the Java interaface type, equivalent to the IID type in COM.
- Returns:
- an Object representing a reference to the component hosting the interface requested.