Package org.ivoa.dm.proposal.management
Class AllocatedBlock
java.lang.Object
org.ivoa.dm.proposal.management.ResourceBlock
org.ivoa.dm.proposal.management.AllocatedBlock
- All Implemented Interfaces:
org.ivoa.vodml.jpa.JPAManipulations,org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
@Entity
@VoDml(id="proposalManagement:AllocatedBlock",
role=objectType)
public class AllocatedBlock
extends ResourceBlock
implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
A block of resources that have been allocated.
objectType: AllocatedBlock
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classA builder class for AllocatedBlock, mainly for use in the functional builder pattern.Nested classes/interfaces inherited from class org.ivoa.dm.proposal.management.ResourceBlock
ResourceBlock.ResourceBlockBuilder -
Field Summary
FieldsFields inherited from class org.ivoa.dm.proposal.management.ResourceBlock
_id, mode, resource -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new AllocatedBlockAllocatedBlock(AllocatedBlock other) Copy Constructor.AllocatedBlock(AllocationGrade grade, ObservingMode mode, Resource resource) full parameter constructor.AllocatedBlock(ResourceBlock superinstance, AllocationGrade grade) Constructor from supertype instance. -
Method Summary
Modifier and TypeMethodDescriptioncopyMe()make a clone of the object taking into account current polymorhic type.static AllocatedBlockcreate a AllocatedBlock in functional builder style.voiddelete(jakarta.persistence.EntityManager em) voidgetGrade()Returns grade ReferencevoidsetGrade(AllocationGrade pGrade) Defines grade Referencevoidupdates any cloned references that are contained within the hierarchy.voidupdateUsing(AllocatedBlock other) Update this object with the content of the given object.Methods inherited from class org.ivoa.dm.proposal.management.ResourceBlock
createResourceBlock, getId, getMode, getResource, setMode, setResource, updateUsing, withResourceMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ivoa.vodml.jpa.JPAManipulationsForObjectType
getId
-
Field Details
-
grade
@VoDml(id="proposalManagement:AllocatedBlock.grade", role=reference, type="proposalManagement:AllocationGrade", typeRole=objectType) protected AllocationGrade gradeReferenceObject grade : . ( Multiplicity : 1 )
-
-
Constructor Details
-
AllocatedBlock
public AllocatedBlock()Creates a new AllocatedBlock -
AllocatedBlock
full parameter constructor.- Parameters:
grade- .mode- .resource- the amount of resource.
-
AllocatedBlock
Copy Constructor. Note that references will remain as is rather than be copied.- Parameters:
other- the object to be copied.
-
AllocatedBlock
Constructor from supertype instance.- Parameters:
superinstance- The supertype.grade- .
-
-
Method Details
-
copyMe
make a clone of the object taking into account current polymorhic type.- Overrides:
copyMein classResourceBlock- Returns:
- the cloned object.
-
updateClonedReferences
public void updateClonedReferences()updates any cloned references that are contained within the hierarchy.- Overrides:
updateClonedReferencesin classResourceBlock
-
updateUsing
Update this object with the content of the given object. Note that references will remain as is rather than be copied.- Parameters:
other- the object to be copied.
-
getGrade
Returns grade Reference- Returns:
- grade Reference
-
setGrade
Defines grade Reference- Parameters:
pGrade- reference to set
-
createAllocatedBlock
create a AllocatedBlock in functional builder style.- Parameters:
f- the functional builder.- Returns:
- an object initialized from the builder.
-
forceLoad
public void forceLoad()- Specified by:
forceLoadin interfaceorg.ivoa.vodml.jpa.JPAManipulations- Overrides:
forceLoadin classResourceBlock
-
delete
public void delete(jakarta.persistence.EntityManager em) - Specified by:
deletein interfaceorg.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>- Overrides:
deletein classResourceBlock
-