Package net.sf.basedb.core.data
Interface DiskConsumableData
-
- All Superinterfaces:
IdentifiableData
,OwnableData
- All Known Implementing Classes:
ExperimentData
,FileData
,RawBioAssayData
public interface DiskConsumableData extends OwnableData
A diskconsumable item is an item that occupies a lot of diskspace and should be controlled by the quota system. TheDiskUsageData
object is ued to hold information about the size, location, owner, etc. of the item.This interface defines Hibernate database mappings for the
diskUsage
property to the database columndiskusage_id
. If a subclass wants to map the property to another column, it should override thegetDiskUsage()
method and add a Hibernate tag in the comment.Hibernate also requires a
setDiskUsage()
method, so this must also be implemented even though it is not required by this interface.Reference implementation
private DiskUsageData diskUsage; public DiskUsageData getDiskUsage() { if (diskUsage == null) diskUsage = new DiskUsageData(); return diskUsage; } void setDiskUsage(DiskUsageData diskUsage) { this.diskUsage = diskUsage; }
Since there is a one-to-one relation between the item and theDiskUsageData
object which should not be changed once it is created the recommended implementation has a package private set method (used only by Hibernate).- Version:
- 2.0
- Author:
- enell
- See Also:
DiskUsageData
,DiskConsumable
, Developer documentation: Quota and disk usage
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DiskUsageData
getDiskUsage()
Get theDiskUsageData
that this item use.-
Methods inherited from interface net.sf.basedb.core.data.IdentifiableData
getId, getVersion
-
Methods inherited from interface net.sf.basedb.core.data.OwnableData
getOwner, setOwner
-
-
-
-
Method Detail
-
getDiskUsage
DiskUsageData getDiskUsage()
Get theDiskUsageData
that this item use.- Hibernate: many-to-one
- column="`diskusage_id`" not-null="true" outer-join="false" unique="true" cascade="all"
-
-