Skip to main content
Skip table of contents

DRMHandler lifecycle

The DRMHandler has a singleton instance, which in turn contains access to the PAK and the PakCore object.

The client application must erase all references to objects returned by the PakCore singleton first; the garbage collector will eventually dispose of these objects. The PakCore singleton must then be released by calling the releaseInstance() method, before all references to it can be dropped. Once the singleton is released, any forgotten objects remaining will become invalid and raise an exception if accessed. This operation can occur at any time and must take place immediately after the PAK enters an error state.

When using the DRMHandler, disposing of the PakCore and its derivatives can be done by disposing of the DRMHandler singleton by simply calling:

JAVA
DRMHandler.getInstance().disposeInstance(true);

The parameter set to true in the call means we want to erase the PAK's database. This is particularly useful if the reason to dispose of the PAK objects is because you want to register with a new license server (also called repersonalisation).

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.