java.lang.Object
org.odpi.openmetadata.frameworks.integration.bitol.common.BitolDocument
org.odpi.openmetadata.frameworks.integration.bitol.odcs.DataContract

public class DataContract extends BitolDocument
This class represents an Open Data Contract Standard (ODCS) data contract as defined by the Bitol project (https://bitol-io.github.io/open-data-contract-standard/). It is used internally in Egeria to pass this information to the integration connectors and view services. A data contract describes a dataset: its schema, data quality checks, service level agreement, support channels, pricing, team, access roles and the servers where it resides. The fundamentals shared with the Open Data Product Standard are inherited from BitolDocument.
  • Field Details

    • CURRENT_API_VERSION

      public static final String CURRENT_API_VERSION
      The version of the Open Data Contract Standard that this bean is aligned with. It is the default apiVersion for new documents.
      See Also:
    • SUPPORTED_API_VERSION_PREFIXES

      public static final List<String> SUPPORTED_API_VERSION_PREFIXES
      The prefixes of the apiVersion values that this bean is able to represent. Older (v2.x) documents have a different top-level structure and are not supported.
  • Constructor Details

    • DataContract

      public DataContract()
      Default constructor
  • Method Details

    • getDataProduct

      public String getDataProduct()
      Return the name of the data product that this contract belongs to (deprecated since v3.1.0 in favour of the ODPS document).
      Returns:
      string name
    • setDataProduct

      public void setDataProduct(String dataProduct)
      Set up the name of the data product that this contract belongs to (deprecated since v3.1.0 in favour of the ODPS document).
      Parameters:
      dataProduct - string name
    • getServers

      public List<DataContractServer> getServers()
      Return the list of servers where the data resides.
      Returns:
      list of servers
    • setServers

      public void setServers(List<DataContractServer> servers)
      Set up the list of servers where the data resides.
      Parameters:
      servers - list of servers
    • getSchema

      public List<DataContractSchemaObject> getSchema()
      Return the list of schema objects (tables, topics, files, ...) described by the contract.
      Returns:
      list of schema objects
    • setSchema

      public void setSchema(List<DataContractSchemaObject> schema)
      Set up the list of schema objects (tables, topics, files, ...) described by the contract.
      Parameters:
      schema - list of schema objects
    • getSupport

      public List<BitolSupportChannel> getSupport()
      Return the list of support and communication channels.
      Returns:
      list of support channels
    • setSupport

      public void setSupport(List<BitolSupportChannel> support)
      Set up the list of support and communication channels.
      Parameters:
      support - list of support channels
    • getPrice

      public DataContractPricing getPrice()
      Return the pricing information.
      Returns:
      pricing structure
    • setPrice

      public void setPrice(DataContractPricing price)
      Set up the pricing information.
      Parameters:
      price - pricing structure
    • getTeam

      public BitolTeam getTeam()
      Return the team responsible for the data contract. Older documents supply a bare list of members; BitolModule (used by BitolDocumentFormatter) accepts this form and wraps it into a team.
      Returns:
      team structure
    • setTeam

      public void setTeam(BitolTeam team)
      Set up the team responsible for the data contract. Older documents supply a bare list of members; BitolModule (used by BitolDocumentFormatter) accepts this form and wraps it into a team.
      Parameters:
      team - team structure
    • getRoles

      public List<DataContractRole> getRoles()
      Return the list of access roles that provide access to the data.
      Returns:
      list of roles
    • setRoles

      public void setRoles(List<DataContractRole> roles)
      Set up the list of access roles that provide access to the data.
      Parameters:
      roles - list of roles
    • getSlaDefaultElement

      public String getSlaDefaultElement()
      Return the default schema element that SLA properties refer to (deprecated since v3.1.0).
      Returns:
      string element reference
    • setSlaDefaultElement

      public void setSlaDefaultElement(String slaDefaultElement)
      Set up the default schema element that SLA properties refer to (deprecated since v3.1.0).
      Parameters:
      slaDefaultElement - string element reference
    • getSlaProperties

      public List<DataContractSLAProperty> getSlaProperties()
      Return the list of service level agreement properties.
      Returns:
      list of SLA properties
    • setSlaProperties

      public void setSlaProperties(List<DataContractSLAProperty> slaProperties)
      Set up the list of service level agreement properties.
      Parameters:
      slaProperties - list of SLA properties
    • getContractCreatedTs

      public String getContractCreatedTs()
      Return the timestamp (UTC, ISO 8601) when the data contract was created.
      Returns:
      string timestamp
    • setContractCreatedTs

      public void setContractCreatedTs(String contractCreatedTs)
      Set up the timestamp (UTC, ISO 8601) when the data contract was created.
      Parameters:
      contractCreatedTs - string timestamp
    • hasSupportedApiVersion

      public boolean hasSupportedApiVersion()
      Return whether the apiVersion of this document is one that this bean is able to represent.
      Specified by:
      hasSupportedApiVersion in class BitolDocument
      Returns:
      boolean flag
    • toString

      public String toString()
      Standard toString method.
      Overrides:
      toString in class BitolDocument
      Returns:
      print out of variables in a JSON-style
    • equals

      public boolean equals(Object objectToCompare)
      Compare the values of the supplied object with those stored in the current object.
      Overrides:
      equals in class BitolDocument
      Parameters:
      objectToCompare - supplied object
      Returns:
      boolean result of comparison
    • hashCode

      public int hashCode()
      Return hash code based on properties.
      Overrides:
      hashCode in class BitolDocument
      Returns:
      int