Class Date

All Implemented Interfaces:
HasTransientProperties, HasFields, SupportsExtensionElements

public class Date extends ExtensibleData implements HasFields
A concluded genealogical date.
  • Constructor Details

    • Date

      public Date()
    • Date

      public Date(Date copy)
  • Method Details

    • id

      public Date id(String id)
      Description copied from class: ExtensibleData
      Build up this object with an id.
      Overrides:
      id in class ExtensibleData
      Parameters:
      id - The id.
      Returns:
      this.
    • extensionElement

      public Date extensionElement(Object element)
      Overrides:
      extensionElement in class ExtensibleData
    • getOriginal

      public String getOriginal()
      The original text as supplied by the user.
      Returns:
      The original text as supplied by the user.
    • setOriginal

      public void setOriginal(String original)
      The original text as supplied by the user.
      Parameters:
      original - The original text as supplied by the user.
    • original

      public Date original(String original)
      Build up this date with original text as supplied by the user.
      Parameters:
      original - the original text.
      Returns:
      this.
    • getFormal

      public String getFormal()
      The standardized and/or normalized formal value.
      Returns:
      The formal value.
    • setFormal

      public void setFormal(String formal)
      The standardized and/or normalized formal value.
      Parameters:
      formal - The formal value.
    • setFormalDate

      public void setFormalDate(GedcomxDate formal)
      The standardized and/or normalized formal value.
      Parameters:
      formal - The formal value.
    • formal

      public Date formal(String formal)
      Build up this date with a formal representation of the date.
      Parameters:
      formal - The formal date.
      Returns:
      this.
    • formal

      public Date formal(GedcomxDate formal)
      Build up this date with a formal representation of the date.
      Parameters:
      formal - The formal date.
      Returns:
      this.
    • getConfidence

      public URI getConfidence()
      The level of confidence the contributor has about the data.
      Returns:
      The level of confidence the contributor has about the data.
    • setConfidence

      public void setConfidence(URI confidence)
      The level of confidence the contributor has about the data.
      Parameters:
      confidence - The level of confidence the contributor has about the data.
    • confidence

      public Date confidence(URI confidence)
      Build up this conclusion with a confidence level.
      Parameters:
      confidence - The confidence level.
      Returns:
      this.
    • confidence

      public Date confidence(ConfidenceLevel confidence)
      Build up this conclusion with a confidence level.
      Parameters:
      confidence - The confidence level.
      Returns:
      this.
    • getKnownConfidenceLevel

      public ConfidenceLevel getKnownConfidenceLevel()
      The value of a the known confidence level, or ConfidenceLevel.OTHER if not known.
      Returns:
      The value of a the known confidence level, or ConfidenceLevel.OTHER if not known.
    • setKnownConfidenceLevel

      public void setKnownConfidenceLevel(ConfidenceLevel level)
      Set the confidence level from a known enumeration of confidence levels.
      Parameters:
      level - The known level.
    • normalizedExtensions

      public Stream<TextValue> normalizedExtensions()
      Create a stream for the normalized value extensions.
      Returns:
      a stream for the normalized value extensions.
    • getNormalizedExtensions

      public List<TextValue> getNormalizedExtensions()
      The list of normalized values for the date, provided for display purposes by the application. Normalized values are not specified by GEDCOM X core, but as extension elements by GEDCOM X RS.
      Returns:
      The list of normalized values for the date, provided for display purposes by the application. Normalized values are not specified by GEDCOM X core, but as extension elements by GEDCOM X RS.
    • setNormalizedExtensions

      public void setNormalizedExtensions(List<TextValue> normalized)
      The list of normalized values for the date, provided for display purposes by the application. Normalized values are not specified by GEDCOM X core, but as extension elements by GEDCOM X RS.
      Parameters:
      normalized - The list of normalized values for the date, provided for display purposes by the application. Normalized values are not specified by GEDCOM X core, but as extension elements by GEDCOM X RS.
    • addNormalizedExtension

      public void addNormalizedExtension(TextValue normalizedExtension)
      Add a normalized extension to the list.
      Parameters:
      normalizedExtension - The normalizedExtension to be added.
    • getFields

      public List<Field> getFields()
      Get the fields being used as evidence.
      Specified by:
      getFields in interface HasFields
      Returns:
      The references to the record fields being used as evidence.
    • setFields

      public void setFields(List<Field> fields)
      Set the list of fields being used as evidence.
      Specified by:
      setFields in interface HasFields
      Parameters:
      fields - - List of fields
    • field

      public Date field(Field field)
      Build up this date with a field.
      Parameters:
      field - The field.
      Returns:
      this.
    • addField

      public void addField(Field field)
      Add a reference to the record field values being used as evidence.
      Parameters:
      field - The field to be added.
    • toString

      public String toString()
      Description copied from class: ExtensibleData
      Provide a simple toString() method.
      Overrides:
      toString in class ExtensibleData
    • accept

      public void accept(GedcomxModelVisitor visitor)
      Accept a visitor.
      Parameters:
      visitor - The visitor.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object