The Free and Open Productivity Suite
Released: Apache OpenOffice 4.1.15
UNO Java Runtime
Class WeakBase

All Implemented Interfaces:
XInterface,, XWeak
Direct Known Subclasses:

public class WeakBase
extends java.lang.Object
implements XWeak,

This class can be used as the base class for UNO components. It implements the capability to be kept weak ( and it implements which is necessary for using the component with StarBasic.

Field Summary
protected static java.util.Map _mapImplementationIds
protected static java.util.Map _mapTypes
Fields inherited from interface
Fields inherited from interface
Constructor Summary
Method Summary
protected  void finalize()
          Override of Object.finalize.
 byte[] getImplementationId()
          Method of XTypeProvider.
 Type[] getTypes()
          Method of XTypeProvider.
 XAdapter queryAdapter()
          Method of XWeak.
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Field Detail


protected static java.util.Map _mapImplementationIds


protected static java.util.Map _mapTypes
Constructor Detail


public WeakBase()
Method Detail


public XAdapter queryAdapter()
Method of XWeak. The returned XAdapter implementation can be used to keap a weak reference to this object.

Specified by:
queryAdapter in interface XWeak
a implementation.


protected void finalize()
                 throws java.lang.Throwable
Override of Object.finalize. When there are no references to this object anymore then the garbage collector calls this method. Thereby causing the adapter object to be notified. The adapter, in turn, notifies all listeners (

finalize in class java.lang.Object


public Type[] getTypes()
Method of XTypeProvider. It returns an array of Type objects which represent all implemented UNO interfaces of this object.

Specified by:
getTypes in interface
Type objects of all implemented interfaces.


public byte[] getImplementationId()
Method of XTypeProvider. It provides an identifier that represents the set of UNO interfaces implemented by this class. All instances of this class which run in the same Java Virtual Machine return the same array. (This only works as long the ClassLoader preserves the class even if no instance exist.)

Specified by:
getImplementationId in interface
identifier as array of bytes

UNO Java Runtime

Apache Software Foundation

Copyright & License | Privacy | Contact Us | Donate | Thanks

Apache, OpenOffice, and the seagull logo are registered trademarks of The Apache Software Foundation. The Apache feather logo is a trademark of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.