Class ParameterGroup

java.lang.Object
org.ivoa.dm.pdl.ParameterGroup
All Implemented Interfaces:
org.ivoa.vodml.jaxb.XmlIdManagement, org.ivoa.vodml.jpa.JPAManipulations, org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>

@Entity @VoDml(id="pdl:ParameterGroup", role=objectType) public class ParameterGroup extends Object implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>, org.ivoa.vodml.jaxb.XmlIdManagement
a group of parameter Definitions. objectType: ParameterGroup
  • Field Details

    • _id

      protected Long _id
      inserted database key
    • name

      @VoDml(id="pdl:ParameterGroup.name", role=attribute, type="ivoa:string", typeRole=primitiveType) protected String name
      Group name. : Attribute name type ivoa:string : multiplicity 1
    • members

      @VoDml(id="pdl:ParameterGroup.members", role=composition, type="pdl:ParameterOrGroup", typeRole=objectType) protected List<ParameterOrGroup> members
      the definitions in the group. composition members : ( Multiplicity : 1..* )
  • Constructor Details

    • ParameterGroup

      public ParameterGroup()
      Creates a new ParameterGroup
    • ParameterGroup

      public ParameterGroup(String name, List<ParameterOrGroup> members)
      full parameter constructor.
      Parameters:
      name - Group name.
      members - the definitions in the group.
    • ParameterGroup

      public ParameterGroup(ParameterGroup other)
      Copy Constructor. Note that references will remain as is rather than be copied.
      Parameters:
      other - the object to be copied.
  • Method Details

    • getId

      public Long getId()
      Specified by:
      getId in interface org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
      Returns:
      the id
    • getXmlId

      public String getXmlId()
      getter for XMLID
      Specified by:
      getXmlId in interface org.ivoa.vodml.jaxb.XmlIdManagement
    • setXmlId

      public void setXmlId(String id)
      Specified by:
      setXmlId in interface org.ivoa.vodml.jaxb.XmlIdManagement
    • hasNaturalKey

      public boolean hasNaturalKey()
      Specified by:
      hasNaturalKey in interface org.ivoa.vodml.jaxb.XmlIdManagement
    • updateClonedReferences

      public void updateClonedReferences()
      updates any cloned references that are contained within the hierarchy.
    • updateUsing

      public void updateUsing(ParameterGroup other)
      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.
    • getName

      public String getName()
      Returns name Attribute.
      Returns:
      name Attribute
    • setName

      public void setName(String pName)
      Set name Attribute.
      Parameters:
      pName - value to set
    • withName

      public ParameterGroup withName(String pName)
      fluent setter for name Attribute.
      Parameters:
      pName - value to set
      Returns:
      ParameterGroup
    • getMembers

      public List<ParameterOrGroup> getMembers()
      Returns members composition as an immutable list.
      Returns:
      members composition.
    • setMembers

      public void setMembers(List<ParameterOrGroup> pMembers)
      Defines whole members composition.
      Parameters:
      pMembers - composition to set.
    • addToMembers

      public void addToMembers(ParameterOrGroup p)
      Add a org.ivoa.dm.pdl.ParameterOrGroup to the composition.
      Parameters:
      p - org.ivoa.dm.pdl.ParameterOrGroup to add
    • removeFromMembers

      public void removeFromMembers(ParameterOrGroup p)
      Remove a org.ivoa.dm.pdl.ParameterOrGroup from the composition.
      Parameters:
      p - org.ivoa.dm.pdl.ParameterOrGroup to remove
    • replaceInMembers

      public void replaceInMembers(ParameterOrGroup _p)
      update a org.ivoa.dm.pdl.ParameterOrGroup in the composition.
      Parameters:
      _p - org.ivoa.dm.pdl.ParameterOrGroup to update the match is done via the database key
    • createParameterGroup

      public static ParameterGroup createParameterGroup(Consumer<ParameterGroup.ParameterGroupBuilder> f)
      create a ParameterGroup in functional builder style.
      Parameters:
      f - the functional builder.
      Returns:
      an object initialized from the builder.
    • forceLoad

      public void forceLoad()
      Specified by:
      forceLoad in interface org.ivoa.vodml.jpa.JPAManipulations
    • delete

      public void delete(jakarta.persistence.EntityManager em)
      Specified by:
      delete in interface org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>