Package org.ivoa.dm.proposal.prop
Class ScienceSpectralWindow
java.lang.Object
org.ivoa.dm.proposal.prop.ScienceSpectralWindow
- All Implemented Interfaces:
org.ivoa.vodml.jpa.JPAManipulations,org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
@Entity
@VoDml(id="proposal:ScienceSpectralWindow",
role=objectType)
public class ScienceSpectralWindow
extends Object
implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
A spectral window for science use.
objectType: ScienceSpectralWindow
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classA builder class for ScienceSpectralWindow, mainly for use in the functional builder pattern. -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Longinserted database keyprotected List<ExpectedSpectralLine>.protected SpectralWindowSetup. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new ScienceSpectralWindowCopy Constructor.ScienceSpectralWindow(SpectralWindowSetup spectralWindowSetup, List<ExpectedSpectralLine> expectedSpectralLine) full parameter constructor. -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a org.ivoa.dm.proposal.prop.ExpectedSpectralLine to the composition.static ScienceSpectralWindowcreate a ScienceSpectralWindow in functional builder style.voiddelete(jakarta.persistence.EntityManager em) voidReturns expectedSpectralLine composition as an immutable list.getId()Returns spectralWindowSetup Attribute.voidRemove a org.ivoa.dm.proposal.prop.ExpectedSpectralLine from the composition.voidupdate a org.ivoa.dm.proposal.prop.ExpectedSpectralLine in the composition.voidsetExpectedSpectralLine(List<ExpectedSpectralLine> pExpectedSpectralLine) Defines whole expectedSpectralLine composition.voidsetSpectralWindowSetup(SpectralWindowSetup pSpectralWindowSetup) Set spectralWindowSetup Attribute.voidupdateUsing(ScienceSpectralWindow other) Update this object with the content of the given object.withSpectralWindowSetup(SpectralWindowSetup pSpectralWindowSetup) fluent setter for spectralWindowSetup Attribute.
-
Field Details
-
_id
inserted database key -
spectralWindowSetup
@VoDml(id="proposal:ScienceSpectralWindow.spectralWindowSetup", role=attribute, type="proposal:SpectralWindowSetup", typeRole=dataType) protected SpectralWindowSetup spectralWindowSetup. : Attribute spectralWindowSetup : multiplicity 0..1 -
expectedSpectralLine
@VoDml(id="proposal:ScienceSpectralWindow.expectedSpectralLine", role=composition, type="proposal:ExpectedSpectralLine", typeRole=objectType) protected List<ExpectedSpectralLine> expectedSpectralLine. composition expectedSpectralLine : ( Multiplicity : 0..* )
-
-
Constructor Details
-
ScienceSpectralWindow
public ScienceSpectralWindow()Creates a new ScienceSpectralWindow -
ScienceSpectralWindow
public ScienceSpectralWindow(SpectralWindowSetup spectralWindowSetup, List<ExpectedSpectralLine> expectedSpectralLine) full parameter constructor.- Parameters:
spectralWindowSetup- .expectedSpectralLine- .
-
ScienceSpectralWindow
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:
getIdin interfaceorg.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>- Returns:
- the id
-
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.
-
getSpectralWindowSetup
Returns spectralWindowSetup Attribute.- Returns:
- spectralWindowSetup Attribute
-
setSpectralWindowSetup
Set spectralWindowSetup Attribute.- Parameters:
pSpectralWindowSetup- value to set
-
withSpectralWindowSetup
fluent setter for spectralWindowSetup Attribute.- Parameters:
pSpectralWindowSetup- value to set- Returns:
- ScienceSpectralWindow
-
getExpectedSpectralLine
Returns expectedSpectralLine composition as an immutable list.- Returns:
- expectedSpectralLine composition.
-
setExpectedSpectralLine
Defines whole expectedSpectralLine composition.- Parameters:
pExpectedSpectralLine- composition to set.
-
addToExpectedSpectralLine
Add a org.ivoa.dm.proposal.prop.ExpectedSpectralLine to the composition.- Parameters:
p- org.ivoa.dm.proposal.prop.ExpectedSpectralLine to add
-
removeFromExpectedSpectralLine
Remove a org.ivoa.dm.proposal.prop.ExpectedSpectralLine from the composition.- Parameters:
p- org.ivoa.dm.proposal.prop.ExpectedSpectralLine to remove
-
replaceInExpectedSpectralLine
update a org.ivoa.dm.proposal.prop.ExpectedSpectralLine in the composition.- Parameters:
_p- org.ivoa.dm.proposal.prop.ExpectedSpectralLine to update the match is done via the database key
-
createScienceSpectralWindow
public static ScienceSpectralWindow createScienceSpectralWindow(Consumer<ScienceSpectralWindow.ScienceSpectralWindowBuilder> f) create a ScienceSpectralWindow 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
-
delete
public void delete(jakarta.persistence.EntityManager em) - Specified by:
deletein interfaceorg.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
-