Class AbstractStorageUsageRecord
java.lang.Object
org.gcube.documentstore.records.implementation.AbstractRecord
org.gcube.accounting.datamodel.BasicUsageRecord
org.gcube.accounting.datamodel.basetypes.AbstractStorageUsageRecord
- All Implemented Interfaces:
Serializable,Comparable<org.gcube.documentstore.records.Record>,UsageRecord,org.gcube.documentstore.records.Record
- Direct Known Subclasses:
AggregatedStorageUsageRecord,StorageUsageRecord
- Author:
- Luca Frosini (ISTI - CNR)
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enumNested classes/interfaces inherited from interface org.gcube.accounting.datamodel.UsageRecord
UsageRecord.OperationResult -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringKEY for : type of data accessed.static final StringKEY for : Quantity of data in terms of KBstatic final StringKEY for : The operation performed over the stored resource.static final Stringstatic final StringKEY for : Qualifies the data in terms of data (e.g.static final StringKEY for : The Owner of the stored Resourcestatic final StringDeprecated.static final StringDeprecated.Fields inherited from class org.gcube.accounting.datamodel.BasicUsageRecord
CONSUMER_ID, OPERATION_RESULT, SCOPEFields inherited from class org.gcube.documentstore.records.implementation.AbstractRecord
aggregatedFields, computation, computedFields, CREATION_TIME, ID, requiredFields, resourceProperties, validationFields inherited from interface org.gcube.documentstore.records.Record
CREATION_TIME, ID, RECORD_TYPE -
Constructor Summary
ConstructorsConstructorDescriptionKEY for : callerQualifierAbstractStorageUsageRecord(Map<String, ? extends Serializable> properties) -
Method Summary
Modifier and TypeMethodDescriptionlongReturn the identity id of the storage resource ownerDeprecated.Deprecated.voidvoidsetDataVolume(long dataVolume) voidsetOperationType(AbstractStorageUsageRecord.OperationType operationType) voidsetProviderURI(URI providerURI) voidsetQualifier(String qualifier) voidsetResourceOwner(String owner) Set the identity id of the storage resource ownervoidsetResourceScope(String scope) Deprecated.voidsetResourceURI(URI resourceURI) Deprecated.Methods inherited from class org.gcube.accounting.datamodel.BasicUsageRecord
getConsumerId, getOperationResult, getQuerableKeys, getScope, init, setConsumerId, setOperationResult, setScopeMethods inherited from class org.gcube.documentstore.records.implementation.AbstractRecord
cleanExtraFields, compareTo, computeField, getAggregatedFields, getAllFields, getComputedFields, getCreationTime, getEndTimeAsCalendar, getEndTimeInMillis, getId, getOperationCount, getRequiredFields, getResourceProperties, getResourceProperty, getStartTimeAsCalendar, getStartTimeInMillis, initializeValidation, isAggregated, removeResourceProperty, setAggregated, setCreationTime, setEndTime, setId, setOperationCount, setResourceProperties, setResourceProperty, setStartTime, timestampToCalendar, toString, validate, validateField, validatePropertiesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.Comparable
compareToMethods inherited from interface org.gcube.documentstore.records.Record
getComputedFields, getCreationTime, getId, getRequiredFields, getResourceProperties, getResourceProperty, removeResourceProperty, setCreationTime, setId, setResourceProperties, setResourceProperty, validate
-
Field Details
-
RESOURCE_OWNER
KEY for : The Owner of the stored Resource- See Also:
-
RESOURCE_SCOPE
Deprecated.KEY for : The Scope where the Resource was stored- See Also:
-
RESOURCE_URI
Deprecated.KEY for : The URI of the Stored Resource- See Also:
-
PROVIDER_URI
- See Also:
-
OPERATION_TYPE
KEY for : The operation performed over the stored resource. The value is a controlled dictionary by StorageUsageRecord.OperationType- See Also:
-
DATA_TYPE
KEY for : type of data accessed. The value is a controlled dictionary by StorageUsageRecord.DataType- See Also:
-
DATA_VOLUME
KEY for : Quantity of data in terms of KB- See Also:
-
QUALIFIER
KEY for : Qualifies the data in terms of data (e.g. MIME type for the Storage, domain for a database)- See Also:
-
-
Constructor Details
-
AbstractStorageUsageRecord
public AbstractStorageUsageRecord()KEY for : callerQualifier -
AbstractStorageUsageRecord
public AbstractStorageUsageRecord(Map<String, ? extends Serializable> properties) throws org.gcube.documentstore.exception.InvalidValueException- Throws:
org.gcube.documentstore.exception.InvalidValueException
-
-
Method Details
-
getRecordType
- Specified by:
getRecordTypein interfaceorg.gcube.documentstore.records.Record- Overrides:
getRecordTypein classBasicUsageRecord
-
getResourceOwner
Return the identity id of the storage resource owner- Returns:
- the identity id of the accounting owner
-
setResourceOwner
public void setResourceOwner(String owner) throws org.gcube.documentstore.exception.InvalidValueException Set the identity id of the storage resource owner- Parameters:
owner- the identity id of the storage resource owner- Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getResourceScope
Deprecated.Return the scope of the storage resource- Returns:
- The scope id of the storage resource
-
setResourceScope
@Deprecated public void setResourceScope(String scope) throws org.gcube.documentstore.exception.InvalidValueException Deprecated.Set the scope of the storage resource- Parameters:
scope- the scope of the storage resource- Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getProviderURI
-
setProviderURI
public void setProviderURI(URI providerURI) throws org.gcube.documentstore.exception.InvalidValueException - Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getResourceURI
Deprecated. -
setResourceURI
@Deprecated public void setResourceURI(URI resourceURI) throws org.gcube.documentstore.exception.InvalidValueException Deprecated.- Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getOperationType
-
setOperationType
public void setOperationType(AbstractStorageUsageRecord.OperationType operationType) throws org.gcube.documentstore.exception.InvalidValueException - Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getDataType
-
setDataType
public void setDataType(AbstractStorageUsageRecord.DataType dataType) throws org.gcube.documentstore.exception.InvalidValueException - Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getDataVolume
public long getDataVolume() -
setDataVolume
public void setDataVolume(long dataVolume) throws org.gcube.documentstore.exception.InvalidValueException - Throws:
org.gcube.documentstore.exception.InvalidValueException
-
getQualifier
-
setQualifier
public void setQualifier(String qualifier) throws org.gcube.documentstore.exception.InvalidValueException - Throws:
org.gcube.documentstore.exception.InvalidValueException
-