class Doctrine_AuditLog_Listener extends Doctrine_Record_Listener (View source)

Doctrine_AuditLog_Listener

Properties

protected array $_options from Doctrine_Record_Listener
protected Doctrine_AuditLog $_auditLog Instance of Doctrine_Auditlog

Methods

setOption($name, $value = null)

setOption sets an option in order to allow flexible listener

getOptions()

getOptions returns all options of this template and the associated values

getOption($name)

getOption returns the value of given option

preSave(Doctrine_Event $event)

No description

postSave(Doctrine_Event $event)

No description

preDelete(Doctrine_Event $event)

Pre delete event hook deletes all related versions This will only delete version records if the auditLog is enabled

postDelete(Doctrine_Event $event)

No description

preUpdate(Doctrine_Event $event)

Pre update event hook for inserting new version record This will only insert a version record if the auditLog is enabled

postUpdate(Doctrine_Event $event)

No description

preInsert(Doctrine_Event $event)

Pre insert event hook for incrementing version number

postInsert(Doctrine_Event $event)

Post insert event hook which creates the new version record This will only insert a version record if the auditLog is enabled

preHydrate(Doctrine_Event $event)

No description

postHydrate(Doctrine_Event $event)

No description

preValidate(Doctrine_Event $event)

No description

void
__construct(Doctrine_AuditLog $auditLog)

Instantiate AuditLog listener and set the Doctrine_AuditLog instance to the class

integer
_getInitialVersion(Doctrine_Record $record)

Get the initial version number for the audit log

integer
_getNextVersion(Doctrine_Record $record)

Get the next version number for the audit log

Details

setOption($name, $value = null)

setOption sets an option in order to allow flexible listener

Parameters

$name
$value

getOptions()

getOptions returns all options of this template and the associated values

getOption($name)

getOption returns the value of given option

Parameters

$name

preSerialize(Doctrine_Event $event)

Parameters

Doctrine_Event $event

postSerialize(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preUnserialize(Doctrine_Event $event)

Parameters

Doctrine_Event $event

postUnserialize(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preDqlSelect(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preSave(Doctrine_Event $event)

Parameters

Doctrine_Event $event

postSave(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preDqlDelete(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preDelete(Doctrine_Event $event)

Pre delete event hook deletes all related versions This will only delete version records if the auditLog is enabled

Parameters

Doctrine_Event $event

postDelete(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preDqlUpdate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preUpdate(Doctrine_Event $event)

Pre update event hook for inserting new version record This will only insert a version record if the auditLog is enabled

Parameters

Doctrine_Event $event

postUpdate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preInsert(Doctrine_Event $event)

Pre insert event hook for incrementing version number

Parameters

Doctrine_Event $event

postInsert(Doctrine_Event $event)

Post insert event hook which creates the new version record This will only insert a version record if the auditLog is enabled

Parameters

Doctrine_Event $event

preHydrate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

postHydrate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

preValidate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

postValidate(Doctrine_Event $event)

Parameters

Doctrine_Event $event

void __construct(Doctrine_AuditLog $auditLog)

Instantiate AuditLog listener and set the Doctrine_AuditLog instance to the class

Parameters

Doctrine_AuditLog $auditLog

Return Value

void

protected integer _getInitialVersion(Doctrine_Record $record)

Get the initial version number for the audit log

Parameters

Doctrine_Record $record

Return Value

integer $initialVersion

protected integer _getNextVersion(Doctrine_Record $record)

Get the next version number for the audit log

Parameters

Doctrine_Record $record

Return Value

integer $nextVersion