Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.serialize
Class QName

    java.lang.Object
      |
      +--org.apache.serialize.QName

Direct Known Subclasses:
  QName

public class QName
extends java.lang.Object

A qualified name. A qualified name has a local name, a namespace URI and a prefix (if known). A `QName` may also specify a non-qualified name by having a null namespace URI.

Constructor Summary
`QName(java.lang.String namespaceURI, java.lang.String localName)` Constructs a new QName with the specified namespace URI and local name.
`QName(java.lang.String namespaceURI, java.lang.String prefix, java.lang.String localName)` Constructs a new QName with the specified namespace URI, prefix and local name.

Method Summary
`boolean` | `equals(java.lang.Object object)`
`boolean` | `equals(java.lang.String ns, java.lang.String localPart)` Override equals and agree that we're equal if the passed object is a string and it matches the name of the arg.
`java.lang.String` | `getLocalName()` Returns the local part of the qualified name.
`java.lang.String` | `getNamespaceURI()` Returns the namespace URI.
`java.lang.String` | `getPrefix()` Returns the namespace prefix.
`java.lang.String` | `toString()`

Methods inherited from class java.lang.Object
`getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### QName

    public QName(java.lang.String namespaceURI,
                 java.lang.String localName)

  Constructs a new QName with the specified namespace URI and local name.
  Parameters:
    `namespaceURI` - The namespace URI if known, or null
    `localName` - The local name

### QName

    public QName(java.lang.String namespaceURI,
                 java.lang.String prefix,
                 java.lang.String localName)

  Constructs a new QName with the specified namespace URI, prefix and local name.
  Parameters:
    `namespaceURI` - The namespace URI if known, or null
    `prefix` - The namespace prefix is known, or null
    `localName` - The local name

Method Detail

### getNamespaceURI

    public java.lang.String getNamespaceURI()

  Returns the namespace URI. Returns null if the namespace URI is not known.
  Returns:
    The namespace URI, or null

### getPrefix

    public java.lang.String getPrefix()

  Returns the namespace prefix. Returns null if the namespace prefix is not known.
  Returns:
    The namespace prefix, or null

### getLocalName

    public java.lang.String getLocalName()

  Returns the local part of the qualified name.
  Returns:
    The local part of the qualified name

### equals

    public boolean equals(java.lang.String ns,
                          java.lang.String localPart)

  Override equals and agree that we're equal if the passed object is a string and it matches the name of the arg.

### equals

    public boolean equals(java.lang.Object object)

  Overrides:
    equals in class java.lang.Object

### toString

    public java.lang.String toString()

  Overrides:
    toString in class java.lang.Object

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2000 Apache XML Project. All Rights Reserved.