Class LocatedEntityRef

java.lang.Object
org.jdom2.Content
org.jdom2.EntityRef
org.jdom2.located.LocatedEntityRef
All Implemented Interfaces:
Serializable, Cloneable, Located, NamespaceAware

public class LocatedEntityRef extends EntityRef implements Located
An XML entity reference. Methods allow the user to manage its name, public id, and system id.
Author:
Rolf Lear
See Also:
  • Constructor Details

    • LocatedEntityRef

      public LocatedEntityRef(String name)
      This will create a new EntityRef with the supplied name.
      Parameters:
      name - String name of element.
      Throws:
      IllegalNameException - if the given name is not a legal XML name.
    • LocatedEntityRef

      public LocatedEntityRef(String name, String systemID)
      This will create a new EntityRef with the supplied name and system id.
      Parameters:
      name - String name of element.
      systemID - system id of the entity reference being constructed
      Throws:
      IllegalNameException - if the given name is not a legal XML name.
      IllegalDataException - if the given system ID is not a legal system literal.
    • LocatedEntityRef

      public LocatedEntityRef(String name, String publicID, String systemID)
      This will create a new EntityRef with the supplied name, public id, and system id.
      Parameters:
      name - String name of element.
      publicID - public id of the entity reference being constructed
      systemID - system id of the entity reference being constructed
      Throws:
      IllegalDataException - if the given system ID is not a legal system literal or the the given public ID is not a legal public ID
      IllegalNameException - if the given name is not a legal XML name.
  • Method Details

    • getLine

      public int getLine()
      Description copied from interface: Located
      Get the line number
      Specified by:
      getLine in interface Located
      Returns:
      the line number
    • getColumn

      public int getColumn()
      Description copied from interface: Located
      Get the column (character on the line).
      Specified by:
      getColumn in interface Located
      Returns:
      the column
    • setLine

      public void setLine(int line)
      Description copied from interface: Located
      Set the line number
      Specified by:
      setLine in interface Located
      Parameters:
      line - the line.
    • setColumn

      public void setColumn(int col)
      Description copied from interface: Located
      Set the column (character on the line).
      Specified by:
      setColumn in interface Located
      Parameters:
      col - The column