Class MCRFieldBaseValue

java.lang.Object
org.mycore.services.fieldquery.MCRFieldBaseValue
Direct Known Subclasses:
MCRQueryCondition

public class MCRFieldBaseValue extends Object
  • Field Details

    • fieldName

      protected String fieldName
      The field this value belongs to
    • value

      protected String value
      The fields's value, as a String
  • Constructor Details

    • MCRFieldBaseValue

      public MCRFieldBaseValue()
    • MCRFieldBaseValue

      public MCRFieldBaseValue(String name, String value)
  • Method Details

    • setFieldName

      public void setFieldName(String fieldName)
    • getFieldName

      public String getFieldName()
      Returns the field this value belongs to
    • setValue

      public void setValue(String value)
      Sets or updates the field value
      Parameters:
      value - the value
    • getValue

      public String getValue()
      Returns the value of the field as a String
      Returns:
      the value of the field as a String
    • buildXML

      public Element buildXML()
      Builds a XML representation of this field's value
      Returns:
      a 'field' element with attribute 'name' and the value as element content
    • parseXML

      public static MCRFieldBaseValue parseXML(Element xml)
      Parses a XML representation of a field value
      Parameters:
      xml - the field value as XML element
      Returns:
      the parsed MCRFieldValue object
    • toString

      public String toString()
      Overrides:
      toString in class Object