com.cumulocity.sdk.client.audit
Interface AuditRecordApi

All Known Implementing Classes:
AuditRecordApiImpl

public interface AuditRecordApi

API for creating and retrieving audit records from the platform


Method Summary
 AuditRecordRepresentation create(AuditRecordRepresentation auditRecord)
          Creates an audit record in the platform.
 AuditRecordRepresentation getAuditRecord(GId gid)
          Gets an audit record by id
 PagedCollectionResource<AuditRecordCollectionRepresentation> getAuditRecords()
          Gets all audit records from the platform
 PagedCollectionResource<AuditRecordCollectionRepresentation> getAuditRecordsByFilter(AuditRecordFilter filter)
          Gets audit records from the platform based on the specified filter
 

Method Detail

getAuditRecord

AuditRecordRepresentation getAuditRecord(GId gid)
                                         throws SDKException
Gets an audit record by id

Parameters:
gid - id of the audit record to search for
Returns:
the audit record with the given id
Throws:
SDKException - if the audit record is not found

create

AuditRecordRepresentation create(AuditRecordRepresentation auditRecord)
                                 throws SDKException
Creates an audit record in the platform. The id of the audit record must not be set, since it will be generated by the platform

Parameters:
auditRecord - the audit record to be created
Returns:
the created audit record with the generated id
Throws:
SDKException - if the audit record could not be generated

getAuditRecords

PagedCollectionResource<AuditRecordCollectionRepresentation> getAuditRecords()
                                                                             throws SDKException
Gets all audit records from the platform

Returns:
collection of audit records with paging functionality
Throws:
SDKException - if the query failed

getAuditRecordsByFilter

PagedCollectionResource<AuditRecordCollectionRepresentation> getAuditRecordsByFilter(AuditRecordFilter filter)
                                                                                     throws SDKException
Gets audit records from the platform based on the specified filter

Parameters:
filter - the filter criteria(s)
Returns:
collection of audit records matched by the filter with paging functionality
Throws:
SDKException - if the query failed


Copyright © 2013 (C) Cumulocity GmbH. All Rights Reserved.