Class PhotometricSystem

java.lang.Object
org.ivoa.dm.demodm.PhotometricSystem
All Implemented Interfaces:
org.ivoa.vodml.jpa.JPAManipulations, org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>

@Entity @VoDml(id="DemoDM:PhotometricSystem", role=objectType) public class PhotometricSystem extends Object implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
. objectType: PhotometricSystem
  • Field Details

    • _id

      protected Long _id
      inserted database key
    • description

      @VoDml(id="DemoDM:PhotometricSystem.description", role=attribute, type="ivoa:string", typeRole=primitiveType) protected String description
      String representation Photometric system. : Attribute description : multiplicity 0..1
    • detectorType

      @VoDml(id="DemoDM:PhotometricSystem.detectorType", role=attribute, type="ivoa:integer", typeRole=primitiveType) protected Integer detectorType
      Type of detector (e.g energy or photon counter). : Attribute detectorType : multiplicity 1
    • photometryFilter

      @VoDml(id="DemoDM:PhotometricSystem.photometryFilter", role=composition, type="DemoDM:PhotometryFilter", typeRole=objectType) protected List<PhotometryFilter> photometryFilter
      . composition photometryFilter : ( Multiplicity : 1..* )
  • Constructor Details

    • PhotometricSystem

      public PhotometricSystem()
      Creates a new PhotometricSystem
    • PhotometricSystem

      public PhotometricSystem(String description, Integer detectorType, List<PhotometryFilter> photometryFilter)
      full parameter constructor.
      Parameters:
      description - String representation Photometric system.
      detectorType - Type of detector (e.g energy or photon counter).
      photometryFilter - .
    • PhotometricSystem

      public PhotometricSystem(PhotometricSystem 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
    • updateUsing

      public void updateUsing(PhotometricSystem 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.
    • getDescription

      public String getDescription()
      Returns description Attribute.
      Returns:
      description Attribute
    • setDescription

      public void setDescription(String pDescription)
      Set description Attribute.
      Parameters:
      pDescription - value to set
    • withDescription

      public PhotometricSystem withDescription(String pDescription)
      fluent setter for description Attribute.
      Parameters:
      pDescription - value to set
      Returns:
      PhotometricSystem
    • getDetectorType

      public Integer getDetectorType()
      Returns detectorType Attribute.
      Returns:
      detectorType Attribute
    • setDetectorType

      public void setDetectorType(Integer pDetectorType)
      Set detectorType Attribute.
      Parameters:
      pDetectorType - value to set
    • withDetectorType

      public PhotometricSystem withDetectorType(Integer pDetectorType)
      fluent setter for detectorType Attribute.
      Parameters:
      pDetectorType - value to set
      Returns:
      PhotometricSystem
    • getPhotometryFilter

      public List<PhotometryFilter> getPhotometryFilter()
      Returns photometryFilter composition as an immutable list.
      Returns:
      photometryFilter composition.
    • setPhotometryFilter

      public void setPhotometryFilter(List<PhotometryFilter> pPhotometryFilter)
      Defines whole photometryFilter composition.
      Parameters:
      pPhotometryFilter - composition to set.
    • addToPhotometryFilter

      public void addToPhotometryFilter(PhotometryFilter p)
      Add a org.ivoa.dm.demodm.PhotometryFilter to the composition.
      Parameters:
      p - org.ivoa.dm.demodm.PhotometryFilter to add
    • removeFromPhotometryFilter

      public void removeFromPhotometryFilter(PhotometryFilter p)
      Remove a org.ivoa.dm.demodm.PhotometryFilter from the composition.
      Parameters:
      p - org.ivoa.dm.demodm.PhotometryFilter to remove
    • replaceInPhotometryFilter

      public void replaceInPhotometryFilter(PhotometryFilter _p)
      update a org.ivoa.dm.demodm.PhotometryFilter in the composition.
      Parameters:
      _p - org.ivoa.dm.demodm.PhotometryFilter to update the match is done via the database key
    • createPhotometricSystem

      public static PhotometricSystem createPhotometricSystem(Consumer<PhotometricSystem.PhotometricSystemBuilder> f)
      create a PhotometricSystem 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>