org.gcube.accounting.datamodel
Class AbstractDelegateUsageRecord

java.lang.Object
  extended by org.gcube.accounting.datamodel.AbstractDelegateUsageRecord
All Implemented Interfaces:
UsageRecord

public abstract class AbstractDelegateUsageRecord
extends Object
implements UsageRecord


Field Summary
protected  UsageRecord ur
           
 
Constructor Summary
AbstractDelegateUsageRecord()
           
AbstractDelegateUsageRecord(UsageRecord ur)
           
 
Method Summary
 String getAggregatedId()
          Return the id of the usage record aggregating this
 String getConsumerId()
          Return the identity of the entity that consumed the resource
 Calendar getCreateTime()
          Return the creation time for this usage record
 String getCreatorId()
          Return the identity of the entity creating this usage record
 Map<String,String> getCustomProperties()
          Return all user-defined properties
 String getCustomProperty(String name)
          Return the value of the given user-defined property
 UsageRecord getDelegateUR()
           
 Calendar getEndTime()
          Return the right end of the time interval covered by this usage record
 String getFullyQualifiedConsumerId()
           
 String getId()
          Return the unique id for this usage record
 Calendar getModifyTime()
          Return the modify time for this usage record
 String getResourceOwner()
          Return the identity of the owner of the resource
 Map<String,String> getResourceSpecificProperties()
          Return all resource-specific properties
 String getResourceSpecificProperty(String name)
          Return the value of the given resource-specific property
 String getResourceType()
          Return the type of the resource this usage records refers to
 Calendar getStartTime()
          Return the left end of the time interval covered by this usage record
 void setAggregatedId(String aggregatedId)
          Set the id of the usage record aggregating this
 void setConsumerId(String consumerId)
          Set the identity of the entity that consumed the resource
 void setCreateTime(Calendar createTime)
          Set the creation time for this usage record
 void setCreatorId(String creatorId)
          Set the identity of the entity creating this usage record
 void setCustomProperties(Map<String,String> props)
          Set all user-defined properties, replacing existing ones
 void setCustomProperty(String name, String value)
          Set the value of the given user-defined property
 void setEndTime(Calendar endTime)
          Set the right end of the time interval covered by this usage record
 void setFullyQualifiedConsumerId(String fqcid)
           
 void setId(String id)
          Set the unique id for this usage record
 void setModifyTime(Calendar modifyTime)
          Set the modification time for this usage record
 void setResourceOwner(String owner)
          Set the scope of the resource
 void setResourceSpecificProperties(Map<String,String> props)
          Set all resource-specific properties, replacing existing ones
 void setResourceSpecificProperty(String name, String value)
          Set the value of the given resource-specific property
 void setResourceType(String resourceType)
          Set the type of the resource this usage records refers to
 void setStartTime(Calendar startTime)
          Set the left end of the time interval covered by this usage record
 void validate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.gcube.accounting.datamodel.UsageRecord
getResourceScope, setResourceScope
 

Field Detail

ur

protected UsageRecord ur
Constructor Detail

AbstractDelegateUsageRecord

public AbstractDelegateUsageRecord()

AbstractDelegateUsageRecord

public AbstractDelegateUsageRecord(UsageRecord ur)
Method Detail

getDelegateUR

public UsageRecord getDelegateUR()

getCreateTime

public Calendar getCreateTime()
Description copied from interface: UsageRecord
Return the creation time for this usage record

Specified by:
getCreateTime in interface UsageRecord
Returns:

setCreateTime

public void setCreateTime(Calendar createTime)
Description copied from interface: UsageRecord
Set the creation time for this usage record

Specified by:
setCreateTime in interface UsageRecord

getModifyTime

public Calendar getModifyTime()
Description copied from interface: UsageRecord
Return the modify time for this usage record

Specified by:
getModifyTime in interface UsageRecord
Returns:

setModifyTime

public void setModifyTime(Calendar modifyTime)
                   throws InvalidValueException
Description copied from interface: UsageRecord
Set the modification time for this usage record

Specified by:
setModifyTime in interface UsageRecord
Throws:
InvalidValueException

getCreatorId

public String getCreatorId()
Description copied from interface: UsageRecord
Return the identity of the entity creating this usage record

Specified by:
getCreatorId in interface UsageRecord

setCreatorId

public void setCreatorId(String creatorId)
Description copied from interface: UsageRecord
Set the identity of the entity creating this usage record

Specified by:
setCreatorId in interface UsageRecord

getConsumerId

public String getConsumerId()
Description copied from interface: UsageRecord
Return the identity of the entity that consumed the resource

Specified by:
getConsumerId in interface UsageRecord
Returns:

setConsumerId

public void setConsumerId(String consumerId)
Description copied from interface: UsageRecord
Set the identity of the entity that consumed the resource

Specified by:
setConsumerId in interface UsageRecord

getFullyQualifiedConsumerId

public String getFullyQualifiedConsumerId()
Specified by:
getFullyQualifiedConsumerId in interface UsageRecord
Returns:

setFullyQualifiedConsumerId

public void setFullyQualifiedConsumerId(String fqcid)
Specified by:
setFullyQualifiedConsumerId in interface UsageRecord

getStartTime

public Calendar getStartTime()
Description copied from interface: UsageRecord
Return the left end of the time interval covered by this usage record

Specified by:
getStartTime in interface UsageRecord
Returns:

setStartTime

public void setStartTime(Calendar startTime)
                  throws InvalidValueException
Description copied from interface: UsageRecord
Set the left end of the time interval covered by this usage record

Specified by:
setStartTime in interface UsageRecord
Throws:
InvalidValueException

getEndTime

public Calendar getEndTime()
Description copied from interface: UsageRecord
Return the right end of the time interval covered by this usage record

Specified by:
getEndTime in interface UsageRecord
Returns:

setEndTime

public void setEndTime(Calendar endTime)
                throws InvalidValueException
Description copied from interface: UsageRecord
Set the right end of the time interval covered by this usage record

Specified by:
setEndTime in interface UsageRecord
Throws:
InvalidValueException

getId

public String getId()
Description copied from interface: UsageRecord
Return the unique id for this usage record

Specified by:
getId in interface UsageRecord
Returns:

setId

public void setId(String id)
Description copied from interface: UsageRecord
Set the unique id for this usage record

Specified by:
setId in interface UsageRecord

getResourceSpecificProperty

public String getResourceSpecificProperty(String name)
Description copied from interface: UsageRecord
Return the value of the given resource-specific property

Specified by:
getResourceSpecificProperty in interface UsageRecord
Returns:

setResourceSpecificProperty

public void setResourceSpecificProperty(String name,
                                        String value)
Description copied from interface: UsageRecord
Set the value of the given resource-specific property

Specified by:
setResourceSpecificProperty in interface UsageRecord

getCustomProperty

public String getCustomProperty(String name)
Description copied from interface: UsageRecord
Return the value of the given user-defined property

Specified by:
getCustomProperty in interface UsageRecord
Returns:

setCustomProperty

public void setCustomProperty(String name,
                              String value)
Description copied from interface: UsageRecord
Set the value of the given user-defined property

Specified by:
setCustomProperty in interface UsageRecord

getResourceSpecificProperties

public Map<String,String> getResourceSpecificProperties()
Description copied from interface: UsageRecord
Return all resource-specific properties

Specified by:
getResourceSpecificProperties in interface UsageRecord
Returns:

setResourceSpecificProperties

public void setResourceSpecificProperties(Map<String,String> props)
Description copied from interface: UsageRecord
Set all resource-specific properties, replacing existing ones

Specified by:
setResourceSpecificProperties in interface UsageRecord

getCustomProperties

public Map<String,String> getCustomProperties()
Description copied from interface: UsageRecord
Return all user-defined properties

Specified by:
getCustomProperties in interface UsageRecord
Returns:

setCustomProperties

public void setCustomProperties(Map<String,String> props)
Description copied from interface: UsageRecord
Set all user-defined properties, replacing existing ones

Specified by:
setCustomProperties in interface UsageRecord

getAggregatedId

public String getAggregatedId()
Description copied from interface: UsageRecord
Return the id of the usage record aggregating this

Specified by:
getAggregatedId in interface UsageRecord
Returns:

setAggregatedId

public void setAggregatedId(String aggregatedId)
Description copied from interface: UsageRecord
Set the id of the usage record aggregating this

Specified by:
setAggregatedId in interface UsageRecord

getResourceType

public String getResourceType()
Description copied from interface: UsageRecord
Return the type of the resource this usage records refers to

Specified by:
getResourceType in interface UsageRecord
Returns:

setResourceType

public void setResourceType(String resourceType)
Description copied from interface: UsageRecord
Set the type of the resource this usage records refers to

Specified by:
setResourceType in interface UsageRecord

getResourceOwner

public String getResourceOwner()
Description copied from interface: UsageRecord
Return the identity of the owner of the resource

Specified by:
getResourceOwner in interface UsageRecord
Returns:

setResourceOwner

public void setResourceOwner(String owner)
Description copied from interface: UsageRecord
Set the scope of the resource

Specified by:
setResourceOwner in interface UsageRecord

validate

public void validate()
              throws InvalidValueException
Specified by:
validate in interface UsageRecord
Throws:
InvalidValueException


Copyright © 2013. All Rights Reserved.