Class MCRMetaHistoryDate.MCRMetaHistoryDateText

java.lang.Object
org.mycore.datamodel.metadata.MCRMetaHistoryDate.MCRMetaHistoryDateText
All Implemented Interfaces:
Cloneable
Enclosing class:
MCRMetaHistoryDate

public static class MCRMetaHistoryDate.MCRMetaHistoryDateText extends Object implements Cloneable
This class describes the structure of pair of language an text. The language notation is in the ISO format.
  • Constructor Details

    • MCRMetaHistoryDateText

      public MCRMetaHistoryDateText()
    • MCRMetaHistoryDateText

      public MCRMetaHistoryDateText(String text, String lang)
  • Method Details

    • getText

      public String getText()
      This method get the text element as String.
      Returns:
      the text
    • getLang

      public String getLang()
      This method get the language element as String of ISO code.
      Returns:
      the language
    • setText

      public void setText(String text, String lang)
      This method set the text element with the corresponding language.
      Parameters:
      text - the text String
      lang - the language String
    • setText

      @Deprecated public void setText(String text)
      Deprecated.
      This method set the text element.
      Parameters:
      text - the text String of a date value
    • setLang

      @Deprecated public void setLang(String lang)
      Deprecated.
      This method set the lang element.
      Parameters:
      lang - the language String of a date value
    • isValid

      public boolean isValid()
      This method validate the content. If lang and text are not empty, it return true otherwise it return false.
      Returns:
      true if the content is valid.
    • equals

      public boolean equals(MCRMetaHistoryDate.MCRMetaHistoryDateText obj)
      This method check the equivalence of lang and text between this object and a given MCRMetaHistoryDateText object.
      Parameters:
      obj - a MCRMetaHistoryDateText instance
      Returns:
      true if both parts are equal
    • clone

      Overrides:
      clone in class Object