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

public abstract class AbstractStorageUsageRecord extends BasicUsageRecord
Author:
Luca Frosini (ISTI - CNR)
See Also:
  • Field Details

    • RESOURCE_OWNER

      public static final String RESOURCE_OWNER
      KEY for : The Owner of the stored Resource
      See Also:
    • RESOURCE_SCOPE

      @Deprecated public static final String RESOURCE_SCOPE
      Deprecated.
      KEY for : The Scope where the Resource was stored
      See Also:
    • RESOURCE_URI

      @Deprecated public static final String RESOURCE_URI
      Deprecated.
      KEY for : The URI of the Stored Resource
      See Also:
    • PROVIDER_URI

      public static final String PROVIDER_URI
      See Also:
    • OPERATION_TYPE

      public static final String OPERATION_TYPE
      KEY for : The operation performed over the stored resource. The value is a controlled dictionary by StorageUsageRecord.OperationType
      See Also:
    • DATA_TYPE

      public static final String DATA_TYPE
      KEY for : type of data accessed. The value is a controlled dictionary by StorageUsageRecord.DataType
      See Also:
    • DATA_VOLUME

      public static final String DATA_VOLUME
      KEY for : Quantity of data in terms of KB
      See Also:
    • QUALIFIER

      public static final String 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

      public String getRecordType()
      Specified by:
      getRecordType in interface org.gcube.documentstore.records.Record
      Overrides:
      getRecordType in class BasicUsageRecord
    • getResourceOwner

      public String 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 public String 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

      public URI getProviderURI()
    • setProviderURI

      public void setProviderURI(URI providerURI) throws org.gcube.documentstore.exception.InvalidValueException
      Throws:
      org.gcube.documentstore.exception.InvalidValueException
    • getResourceURI

      @Deprecated public URI getResourceURI()
      Deprecated.
    • setResourceURI

      @Deprecated public void setResourceURI(URI resourceURI) throws org.gcube.documentstore.exception.InvalidValueException
      Deprecated.
      Throws:
      org.gcube.documentstore.exception.InvalidValueException
    • getOperationType

      public AbstractStorageUsageRecord.OperationType 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

      public String getQualifier()
    • setQualifier

      public void setQualifier(String qualifier) throws org.gcube.documentstore.exception.InvalidValueException
      Throws:
      org.gcube.documentstore.exception.InvalidValueException