Class Draw

All Implemented Interfaces:
Peer

public final class Draw extends Container
A class to represent the XFA draw object. A draw describes a container capable of non-interactive data content.
  • Constructor Details

    • Draw

      public Draw(Element parent, Node prevSibling)
      Instantiates a draw container.
      Parameters:
      parent - the draw's parent, if any.
      prevSibling - the draw's previous sibling, if any.
  • Method Details

    • getRawValue

      public String getRawValue()
      Get the raw value for this draw, no formatting.
      Returns:
      the unformatted raw value for this draw, an empty string for boilerplate content, or null if the content is null.
    • setRawValue

      public void setRawValue(String sString)
      Set the raw value for this draw, no formatting.
      Parameters:
      sString - the unformatted raw value for this draw.
      Throws:
      UnsupportedOperationException - if you try and set the value of a boilerplate content.
    • getAttribute

      public Attribute getAttribute(int eTag, boolean bPeek, boolean bValidate)
      Description copied from class: Element
      Gets this element's attribute whose attribute tag is given.

      To peek at an attribute, set the peek argument to true. If the attribute is present, it is returned; otherwise null is returned.

      To create an attribute, set the peek argument to false. If the attribute is absent, a default attribute is created and returned; for attributes with no default, null is returned.

      If validation argument is true, and the validation fails, this method throws.

      Overrides:
      getAttribute in class Container
      Parameters:
      eTag - the tag of the attribute.
      bPeek - whether to peek at the attribute or not.
      bValidate - whether to validate the attribute or not.
      Returns:
      the attribute.
    • getScriptTable

      public ScriptTable getScriptTable()
      Overrides:
      getScriptTable in class Container
    • isWidthGrowSupported

      public boolean isWidthGrowSupported()
      Description copied from class: Container
      Return whether or not this container support growable widths This does not indicate whether the container height is currently growable, just whether it's supported by this container type.

      Comments Helps distinguish - ie text draws supporting growing but arc draws do not.

      Overrides:
      isWidthGrowSupported in class Container
    • isHeightGrowSupported

      public boolean isHeightGrowSupported()
      Description copied from class: Container
      Returns whether or not this container support growable heights. This does not indicate whether the container height is currently growable, just whether it's supported by this container type.
      Overrides:
      isHeightGrowSupported in class Container