PrimoBurner(tm) for C++  4.4
CD, DVD and Blu-ray Software Development Kit
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Pages
Engine Class Referenceabstract

PrimoBurner Engine. More...

#include <PrimoBurnerAPI.h>

Inherits Reference.

Public Member Functions

virtual DeviceEnumcreateDeviceEnumerator ()=0
 Enumerates the optical devices installed in the system. More...
 
virtual DevicecreateDeviceFromHandle (handle_t handle)=0
 Creates a Device object from device handle. More...
 
virtual const ErrorInfoerror () const =0
 Gets error information about the last operation. More...
 
virtual bool_t initialize ()=0
 Initializes the engine object.
 
virtual void setCallback (EngineCallback *callback)=0
 Sets a notification callback object to receive device change notifications (arrival/removal of devices and media) More...
 
virtual void shutdown ()=0
 The Shutdown method shuts down the object. More...
 
- Public Member Functions inherited from Reference
virtual int32_t release () const =0
 Releases the instance. More...
 
virtual int32_t retain () const =0
 Retains the instance. More...
 
virtual int32_t retainCount () const =0
 Returns the current reference count. More...
 

Detailed Description

PrimoBurner Engine.

Member Function Documentation

virtual DeviceEnum* createDeviceEnumerator ( )
pure virtual

Enumerates the optical devices installed in the system.

Returns
DeviceEnum object that can be used for creating device instances.
NULL if engine has not been initialized and also sets error to EngineError::NotInitialized.
Remarks
On Windows this method enumerates only devices, which have drive letters assigned.
See Also
DeviceEnum
virtual Device* createDeviceFromHandle ( handle_t  handle)
pure virtual

Creates a Device object from device handle.

Parameters
handleOS handle obtained from Device::deviceHandle.
Returns
A new Device object.
NULL if engine has not been initialized and also sets error to EngineError::NotInitialized.
Remarks
Together with Device::deviceHandle this method allows to pass a Device between different processes and library versions.
On Linux the method always returns NULL.
See Also
Object Management
virtual const ErrorInfo* error ( ) const
pure virtual

Gets error information about the last operation.

Returns
A pointer to an ErrorInfo object.
virtual void setCallback ( EngineCallback callback)
pure virtual

Sets a notification callback object to receive device change notifications (arrival/removal of devices and media)

Parameters
callbackA pointer to an object that implements the EngineCallback interface.

Internally the EngineCallback is retained (if not NULL). The previous EngineCallback is released (if not NULL). The EngineCallback instance is released when the Engine itself is being destroyed.

NOTE: If the user code inherits from EngineCallback but does not override primo::Reference::release() and primo::Reference::retain() it must ensure that the callback instance is valid until it is used by the engine. This is so because the default implementation of primo::Reference in EngineCallback keeps a constant reference count of 1.

See Also
EngineCallback
virtual void shutdown ( )
pure virtual

The Shutdown method shuts down the object.

Shutdown unlocks any devices that have been locked and frees the internal structures associated with every device.