toolbox.services.util.audit
Class AuditEntry

Package class diagram package AuditEntry
java.lang.Object
  extended by toolbox.services.util.audit.AuditEntry
All Implemented Interfaces:
java.io.Serializable, DaoBean

public class AuditEntry
extends java.lang.Object
implements DaoBean, java.io.Serializable

AuditEntry bean generated by the Toolbox Bean Generator.

This bean implements the DaoBean interface that allows it to be persisted by sub-class instances of the toolbox.services.dao.DaoService class.

See Also:
Serialized Form

Constructor Summary
AuditEntry()
          Default constructor to initialise the internal Map for storing bean properties.
 
Method Summary
static AuditEntry create(java.util.Map map)
          Create a new AuditEntry bean instance using the properties in the given Map as the values of the bean properties.
 java.lang.String getApplication()
          Return the application property.
 java.util.Map getMap()
          Return the Map containing the bean properties.
 java.lang.String getMapping(java.lang.String prop)
          Return the mapped value for the provided property name.
 java.util.Map getMappings()
          Return the Map containing the property mappings.
 java.lang.String getNewProperties()
          Return the newProperties property.
 java.lang.String getOldProperties()
          Return the oldProperties property.
 java.lang.String getOperation()
          Return the operation property.
 java.lang.String getOperationResult()
          Return the operationResult property.
 java.util.Date getOperationTime()
          Return the operationTime property.
 java.lang.String getRole()
          Return the role property.
 java.lang.String getUserId()
          Return the userId property.
 void setApplication(java.lang.String application)
          Set the application property.
 void setMap(java.util.Map map)
          Set the Map containing the bean properties.
 void setNewProperties(java.lang.String newProperties)
          Set the newProperties property.
 void setOldProperties(java.lang.String oldProperties)
          Set the oldProperties property.
 void setOperation(java.lang.String operation)
          Set the operation property.
 void setOperationResult(java.lang.String operationResult)
          Set the operationResult property.
 void setOperationTime(java.util.Date operationTime)
          Set the operationTime property.
 void setRole(java.lang.String role)
          Set the role property.
 void setUserId(java.lang.String userId)
          Set the userId property.
 java.lang.String toString()
          Return a String representation of this DaoBean instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

AuditEntry

public AuditEntry()
Default constructor to initialise the internal Map for storing bean properties.

Method Detail

setUserId

public void setUserId(java.lang.String userId)
Set the userId property.

Parameters:
userId - New value of the userId property.

getUserId

public java.lang.String getUserId()
Return the userId property.

Returns:
String containinig the value of the userId property.

setRole

public void setRole(java.lang.String role)
Set the role property.

Parameters:
role - New value of the role property.

getRole

public java.lang.String getRole()
Return the role property.

Returns:
String containinig the value of the role property.

setApplication

public void setApplication(java.lang.String application)
Set the application property.

Parameters:
application - New value of the application property.

getApplication

public java.lang.String getApplication()
Return the application property.

Returns:
String containinig the value of the application property.

setOperation

public void setOperation(java.lang.String operation)
Set the operation property.

Parameters:
operation - New value of the operation property.

getOperation

public java.lang.String getOperation()
Return the operation property.

Returns:
String containinig the value of the operation property.

setOperationResult

public void setOperationResult(java.lang.String operationResult)
Set the operationResult property.

Parameters:
operationResult - New value of the operationResult property.

getOperationResult

public java.lang.String getOperationResult()
Return the operationResult property.

Returns:
String containinig the value of the operationResult property.

setOperationTime

public void setOperationTime(java.util.Date operationTime)
Set the operationTime property.

Parameters:
operationTime - New value of the operationTime property.

getOperationTime

public java.util.Date getOperationTime()
Return the operationTime property.

Returns:
Date containinig the value of the operationTime property.

setOldProperties

public void setOldProperties(java.lang.String oldProperties)
Set the oldProperties property.

Parameters:
oldProperties - New value of the oldProperties property.

getOldProperties

public java.lang.String getOldProperties()
Return the oldProperties property.

Returns:
String containinig the value of the oldProperties property.

setNewProperties

public void setNewProperties(java.lang.String newProperties)
Set the newProperties property.

Parameters:
newProperties - New value of the newProperties property.

getNewProperties

public java.lang.String getNewProperties()
Return the newProperties property.

Returns:
String containinig the value of the newProperties property.

setMap

public void setMap(java.util.Map map)
Set the Map containing the bean properties.

Specified by:
setMap in interface DaoBean
Parameters:
map - Map containing bean properties.

getMap

public java.util.Map getMap()
Return the Map containing the bean properties.

Specified by:
getMap in interface DaoBean
Returns:
Map containing bean properties.

getMapping

public java.lang.String getMapping(java.lang.String prop)
Return the mapped value for the provided property name.

Specified by:
getMapping in interface DaoBean
Parameters:
prop - Return the mapping for this property.
Returns:
String containing the mapping for the provided property.

getMappings

public java.util.Map getMappings()
Return the Map containing the property mappings.

Specified by:
getMappings in interface DaoBean
Returns:
Map instance containing property mappings.

create

public static AuditEntry create(java.util.Map map)
                         throws java.lang.Exception
Create a new AuditEntry bean instance using the properties in the given Map as the values of the bean properties.

Property mappings are done using Java Reflection and is performed as follows:

The keys in the Map are used as the names of the bean properties. If the Map contains a key with the value name it will be translated into a method call that will invoke the setName(...) method on the target bean using the value associated with the key in the Map.

Parameters:
map - Map containing bean properties.
Returns:
AuditEntry bean instance.
Throws:
java.lang.Exception - if the bean cannot be created.

toString

public java.lang.String toString()
Return a String representation of this DaoBean instance.

Overrides:
toString in class java.lang.Object
Returns:
String representation of the properties of this bean.