Package org.ivoa.dm.proposal.prop
Class TechnicalGoal
java.lang.Object
org.ivoa.dm.proposal.prop.TechnicalGoal
- All Implemented Interfaces:
org.ivoa.vodml.jaxb.XmlIdManagement
,org.ivoa.vodml.jpa.JPAManipulations
,org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
@Entity
@VoDml(id="proposal:TechnicalGoal",
role=objectType)
public class TechnicalGoal
extends Object
implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>, org.ivoa.vodml.jaxb.XmlIdManagement
collects together the technical goals of the proposal.
objectType: TechnicalGoal
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
A builder class for TechnicalGoal, mainly for use in the functional builder pattern. -
Field Summary
Modifier and TypeFieldDescriptionprotected Long
inserted database keyprotected PerformanceParameters
.protected List<ScienceSpectralWindow>
. -
Constructor Summary
ConstructorDescriptionCreates a new TechnicalGoalTechnicalGoal
(PerformanceParameters performance, List<ScienceSpectralWindow> spectrum) full parameter constructor.TechnicalGoal
(TechnicalGoal other) Copy Constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Add a org.ivoa.dm.proposal.prop.ScienceSpectralWindow to the composition.static TechnicalGoal
create a TechnicalGoal in functional builder style.void
getId()
Returns performance Attribute.Returns spectrum composition as an immutable list.getXmlId()
getter for XMLIDboolean
void
persistRefs
(jakarta.persistence.EntityManager _em) Deprecated.generally better to use the model level reference persistence as only this can deal with "contained" references properly.void
Remove a org.ivoa.dm.proposal.prop.ScienceSpectralWindow from the composition.void
update a org.ivoa.dm.proposal.prop.ScienceSpectralWindow in the composition.void
setPerformance
(PerformanceParameters pPerformance) Set performance Attribute.void
setSpectrum
(List<ScienceSpectralWindow> pSpectrum) Defines whole spectrum composition.void
void
updateUsing
(TechnicalGoal other) Update this object with the content of the given object.withPerformance
(PerformanceParameters pPerformance) fluent setter for performance Attribute.
-
Field Details
-
_id
inserted database key -
performance
@VoDml(id="proposal:TechnicalGoal.performance", role=composition, type="proposal:PerformanceParameters", typeRole=objectType) protected PerformanceParameters performance. composition performance : ( Multiplicity : 1 ) -
spectrum
@VoDml(id="proposal:TechnicalGoal.spectrum", role=composition, type="proposal:ScienceSpectralWindow", typeRole=objectType) protected List<ScienceSpectralWindow> spectrum. composition spectrum : ( Multiplicity : 1..* )
-
-
Constructor Details
-
TechnicalGoal
public TechnicalGoal()Creates a new TechnicalGoal -
TechnicalGoal
full parameter constructor.- Parameters:
performance
- .spectrum
- .
-
TechnicalGoal
Copy Constructor. Note that references will remain as is rather than be copied.- Parameters:
other
- the object to be copied.
-
-
Method Details
-
getId
- Specified by:
getId
in interfaceorg.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
- Returns:
- the id
-
getXmlId
getter for XMLID- Specified by:
getXmlId
in interfaceorg.ivoa.vodml.jaxb.XmlIdManagement
-
setXmlId
- Specified by:
setXmlId
in interfaceorg.ivoa.vodml.jaxb.XmlIdManagement
-
hasNaturalKey
public boolean hasNaturalKey()- Specified by:
hasNaturalKey
in interfaceorg.ivoa.vodml.jaxb.XmlIdManagement
-
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.
-
getPerformance
Returns performance Attribute.- Returns:
- performance Attribute
-
setPerformance
Set performance Attribute.- Parameters:
pPerformance
- value to set
-
withPerformance
fluent setter for performance Attribute.- Parameters:
pPerformance
- value to set- Returns:
- TechnicalGoal
-
getSpectrum
Returns spectrum composition as an immutable list.- Returns:
- spectrum composition.
-
setSpectrum
Defines whole spectrum composition.- Parameters:
pSpectrum
- composition to set.
-
addToSpectrum
Add a org.ivoa.dm.proposal.prop.ScienceSpectralWindow to the composition.- Parameters:
p
- org.ivoa.dm.proposal.prop.ScienceSpectralWindow to add
-
removeFromSpectrum
Remove a org.ivoa.dm.proposal.prop.ScienceSpectralWindow from the composition.- Parameters:
p
- org.ivoa.dm.proposal.prop.ScienceSpectralWindow to remove
-
replaceInSpectrum
update a org.ivoa.dm.proposal.prop.ScienceSpectralWindow in the composition.- Parameters:
_p
- org.ivoa.dm.proposal.prop.ScienceSpectralWindow to update the match is done via the database key
-
createTechnicalGoal
create a TechnicalGoal in functional builder style.- Parameters:
f
- the functional builder.- Returns:
- an object initialized from the builder.
-
forceLoad
public void forceLoad()- Specified by:
forceLoad
in interfaceorg.ivoa.vodml.jpa.JPAManipulations
-
persistRefs
Deprecated.generally better to use the model level reference persistence as only this can deal with "contained" references properly.- Specified by:
persistRefs
in interfaceorg.ivoa.vodml.jpa.JPAManipulations
-