Class TextInputField

java.lang.Object
com.independentsoft.office.odf.fields.Field
com.independentsoft.office.odf.fields.TextInputField
All Implemented Interfaces:
IContentElement, IParagraphContent

public class TextInputField extends Field
Represents a text input field. A text input field is used in a user interface to prompt a user to input text. This text is stored and displayed as the content of this element until it is replaced by a user.
  • Constructor Details

    • TextInputField

      public TextInputField()
      Initializes a new instance of the TextInputField class.
    • TextInputField

      public TextInputField(InternalXMLStreamReader reader) throws XMLStreamException
      Instantiates a new text input field.
      Parameters:
      reader - the reader
      Throws:
      XMLStreamException - the xML stream exception
  • Method Details

    • getContentElements

      public List<IContentElement> getContentElements()
      Returns all content elements.
      Specified by:
      getContentElements in interface IContentElement
      Specified by:
      getContentElements in class Field
      Returns:
      A collection of content elements.
    • getParent

      public IContentElement getParent()
      Returns the parent content element.
      Specified by:
      getParent in interface IContentElement
      Overrides:
      getParent in class Field
      Returns:
      the parent
    • setParent

      public void setParent(IContentElement parent)
      Sets the parent content element.
      Specified by:
      setParent in interface IContentElement
      Overrides:
      setParent in class Field
      Parameters:
      parent - the new parent
    • clone

      public TextInputField clone()
      Creates a new object that is a deep copy of the current instance.
      Specified by:
      clone in interface IContentElement
      Specified by:
      clone in interface IParagraphContent
      Specified by:
      clone in class Field
      Returns:
      A new object that is a copy of this instance.
    • toString

      public String toString()
      Converts the value of the current TextInputField object to its equivalent string representation.
      Overrides:
      toString in class Object
      Returns:
      the string
    • getDescription

      public String getDescription()
      Gets a message that is displayed when users are prompted for input.
      Returns:
      the description
    • setDescription

      public void setDescription(String description)
      Sets a message that is displayed when users are prompted for input.
      Parameters:
      description - the new description
    • getValue

      public String getValue()
      Gets the text input.
      Returns:
      the value
    • setValue

      public void setValue(String value)
      Sets the text input.
      Parameters:
      value - the new value