Nuxeo Enterprise Platform 5.4

org.nuxeo.ecm.platform.audit.search.resources.indexing
Class AuditIndexableResourceImpl

java.lang.Object
  extended by org.nuxeo.ecm.core.search.api.client.indexing.resources.AbstractIndexableResource
      extended by org.nuxeo.ecm.platform.audit.search.resources.indexing.AuditIndexableResourceImpl
All Implemented Interfaces:
java.io.Serializable, IndexableResource, AuditIndexableResource

public class AuditIndexableResourceImpl
extends AbstractIndexableResource
implements AuditIndexableResource

Audit indexable resource implementation.

Takes care of fetching log entries, generating log entry data maps and returns log entry data given a key.

Author:
Julien Anguenot
See Also:
Serialized Form

Constructor Summary
AuditIndexableResourceImpl()
           
AuditIndexableResourceImpl(long logUUID)
           
 
Method Summary
 ACP computeAcp()
          Computes an ACP for the given resource.
 java.lang.String computeId()
          Computes the resource unique id.
 java.util.Map<java.lang.String,java.io.Serializable> getLogEntryDataMapFor(long id)
          Returns the log entry data map for a log entry given its id.
 java.io.Serializable getValueFor(java.lang.String indexableDataName)
          Returns the value for a given indexable data name.
 
Methods inherited from class org.nuxeo.ecm.core.search.api.client.indexing.resources.AbstractIndexableResource
getConfiguration, getName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.nuxeo.ecm.core.search.api.client.indexing.resources.IndexableResource
getConfiguration, getName
 

Constructor Detail

AuditIndexableResourceImpl

public AuditIndexableResourceImpl()

AuditIndexableResourceImpl

public AuditIndexableResourceImpl(long logUUID)
Method Detail

getValueFor

public java.io.Serializable getValueFor(java.lang.String indexableDataName)
                                 throws IndexingException
Description copied from interface: IndexableResource
Returns the value for a given indexable data name.

Specified by:
getValueFor in interface IndexableResource
Parameters:
indexableDataName - the actual indexable data name resource side.
Returns:
a serializable object holding the value.
Throws:
IndexingException - TODO

getLogEntryDataMapFor

public java.util.Map<java.lang.String,java.io.Serializable> getLogEntryDataMapFor(long id)
                                                                           throws IndexingException
Description copied from interface: AuditIndexableResource
Returns the log entry data map for a log entry given its id.

Specified by:
getLogEntryDataMapFor in interface AuditIndexableResource
Parameters:
id - the log entry identifier.
Returns:
a map from string to serializable.
Throws:
IndexingException

computeId

public java.lang.String computeId()
Description copied from interface: IndexableResource
Computes the resource unique id. This can be costly, since it may involve fetching data, computing hash codes, etc.

Specified by:
computeId in interface IndexableResource
Returns:
the resource id

computeAcp

public ACP computeAcp()
Description copied from interface: IndexableResource
Computes an ACP for the given resource.

The returned value applies to all the resources that may be associated with the present one in an IndexableResources. Confidence in the validity of said value must be as strong as it gets. The counterpart is that the caller must interpret null return values as a lack of info from this and perform other computations.

Specified by:
computeAcp in interface IndexableResource
Overrides:
computeAcp in class AbstractIndexableResource
Returns:
null, which encourages the caller to continue investigating.

Nuxeo Enterprise Platform 5.4

Copyright © 2010 Nuxeo SAS. All Rights Reserved.