Class TableSet

java.lang.Object
org.ivoa.dm.registry.vodataservice.TableSet
All Implemented Interfaces:
org.ivoa.vodml.jpa.JPAManipulations, org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
Direct Known Subclasses:
Tableset

@Entity @VoDml(id="VODataService:TableSet", role=objectType) public class TableSet extends Object implements org.ivoa.vodml.jpa.JPAManipulationsForObjectType<Long>
The set of tables hosted by a resource. objectType: TableSet
  • Field Details

    • _id

      protected Long _id
      inserted database key
    • schema

      @VoDml(id="VODataService:TableSet.schema", role=composition, type="VODataService:TableSchema", typeRole=objectType) protected List<TableSchema> schema
      A named description of a group of logically related tables. The name given by the “name” child element must be unique within this TableSet instance. If there is only one schema in this set and/or there is no locally appropriate name to provide, the name can be set to “default”. This aggregation does not need to map to an actual database, catalogue, or schema, though the publisher may choose to aggregate along such designations. Particular service protocols may require stricter patterns. composition schema : ( Multiplicity : 1..* )
  • Constructor Details

    • TableSet

      public TableSet()
      Creates a new TableSet
    • TableSet

      public TableSet(List<TableSchema> schema)
      full parameter constructor.
      Parameters:
      schema - A named description of a group of logically related tables. The name given by the “name” child element must be unique within this TableSet instance. If there is only one schema in this set and/or there is no locally appropriate name to provide, the name can be set to “default”. This aggregation does not need to map to an actual database, catalogue, or schema, though the publisher may choose to aggregate along such designations. Particular service protocols may require stricter patterns.
    • TableSet

      public TableSet(TableSet 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
    • copyMe

      public TableSet copyMe()
      make a clone of the object taking into account current polymorhic type.
      Returns:
      the cloned object.
    • updateUsing

      public void updateUsing(TableSet 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.
    • getSchema

      public List<TableSchema> getSchema()
      Returns schema composition as an immutable list.
      Returns:
      schema composition.
    • setSchema

      public void setSchema(List<TableSchema> pSchema)
      Defines whole schema composition.
      Parameters:
      pSchema - composition to set.
    • addToSchema

      public void addToSchema(TableSchema p)
      Add a org.ivoa.dm.registry.vodataservice.TableSchema to the composition.
      Parameters:
      p - org.ivoa.dm.registry.vodataservice.TableSchema to add
    • removeFromSchema

      public void removeFromSchema(TableSchema p)
      Remove a org.ivoa.dm.registry.vodataservice.TableSchema from the composition.
      Parameters:
      p - org.ivoa.dm.registry.vodataservice.TableSchema to remove
    • replaceInSchema

      public void replaceInSchema(TableSchema _p)
      update a org.ivoa.dm.registry.vodataservice.TableSchema in the composition.
      Parameters:
      _p - org.ivoa.dm.registry.vodataservice.TableSchema to update the match is done via the database key
    • createTableSet

      public static TableSet createTableSet(Consumer<TableSet.TableSetBuilder> f)
      create a TableSet 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>