Added in API level 1

Locator2Impl

public class Locator2Impl
extends LocatorImpl implements Locator2

java.lang.Object
   ↳ org.xml.sax.helpers.LocatorImpl
     ↳ org.xml.sax.ext.Locator2Impl


SAX2 extension helper for holding additional Entity information, implementing the Locator2 interface.

This module, both source code and documentation, is in the Public Domain, and comes with NO WARRANTY.

This is not part of core-only SAX2 distributions.

Summary

Public constructors

Locator2Impl()

Construct a new, empty Locator2Impl object.

Locator2Impl(Locator locator)

Copy an existing Locator or Locator2 object.

Public methods

String getEncoding()

Returns the current value of the encoding property.

String getXMLVersion()

Returns the current value of the version property.

void setEncoding(String encoding)

Assigns the current value of the encoding property.

void setXMLVersion(String version)

Assigns the current value of the version property.

Inherited methods

int getColumnNumber()

Return the saved column number (1-based).

int getLineNumber()

Return the saved line number (1-based).

String getPublicId()

Return the saved public identifier.

String getSystemId()

Return the saved system identifier.

void setColumnNumber(int columnNumber)

Set the column number for this locator (1-based).

void setLineNumber(int lineNumber)

Set the line number for this locator (1-based).

void setPublicId(String publicId)

Set the public identifier for this locator.

void setSystemId(String systemId)

Set the system identifier for this locator.

Object clone()

Creates and returns a copy of this object.

boolean equals(Object obj)

Indicates whether some other object is "equal to" this one.

void finalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

final Class<?> getClass()

Returns the runtime class of this Object.

int hashCode()

Returns a hash code value for the object.

final void notify()

Wakes up a single thread that is waiting on this object's monitor.

final void notifyAll()

Wakes up all threads that are waiting on this object's monitor.

String toString()

Returns a string representation of the object.

final void wait(long timeoutMillis, int nanos)

Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

final void wait(long timeoutMillis)

Causes the current thread to wait until it is awakened, typically by being notified or interrupted, or until a certain amount of real time has elapsed.

final void wait()

Causes the current thread to wait until it is awakened, typically by being notified or interrupted.

abstract int getColumnNumber()

Return the column number where the current document event ends.

abstract int getLineNumber()

Return the line number where the current document event ends.

abstract String getPublicId()

Return the public identifier for the current document event.

abstract String getSystemId()

Return the system identifier for the current document event.

abstract String getEncoding()

Returns the name of the character encoding for the entity.

abstract String getXMLVersion()

Returns the version of XML used for the entity.

Public constructors

Locator2Impl

Added in API level 1
public Locator2Impl ()

Construct a new, empty Locator2Impl object. This will not normally be useful, since the main purpose of this class is to make a snapshot of an existing Locator.

Locator2Impl

Added in API level 1
public Locator2Impl (Locator locator)

Copy an existing Locator or Locator2 object. If the object implements Locator2, values of the encoding and versionstrings are copied, otherwise they set to null.

Parameters
locator Locator: The existing Locator object.

Public methods

getEncoding

Added in API level 1
public String getEncoding ()

Returns the current value of the encoding property.

Returns
String the current value of the encoding property.

getXMLVersion

Added in API level 1
public String getXMLVersion ()

Returns the current value of the version property.

Returns
String the current value of the version property.

setEncoding

Added in API level 1
public void setEncoding (String encoding)

Assigns the current value of the encoding property.

Parameters
encoding String: the new "encoding" value

See also:

setXMLVersion

Added in API level 1
public void setXMLVersion (String version)

Assigns the current value of the version property.

Parameters
version String: the new "version" value

See also: