Class UnresolvedQName.Unqualified
- java.lang.Object
-
- org.opendaylight.yangtools.yang.common.AbstractQName
-
- org.opendaylight.yangtools.yang.common.UnresolvedQName
-
- org.opendaylight.yangtools.yang.common.UnresolvedQName.Unqualified
-
- All Implemented Interfaces:
Serializable
,Comparable<UnresolvedQName.Unqualified>
,Identifier
,Immutable
,MutationBehaviour<Immutable>
,WritableObject
- Enclosing class:
- UnresolvedQName
public static final class UnresolvedQName.Unqualified extends UnresolvedQName implements Comparable<UnresolvedQName.Unqualified>
An unresolved, unqualifiedQName
. It is guaranteed to hold a validAbstractQName.getLocalName()
, in the default namespace, which is not resolved. A resolvedQName
can be constructed throughAbstractQName.bindTo(QNameModule)
.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.opendaylight.yangtools.yang.common.UnresolvedQName
UnresolvedQName.Qualified, UnresolvedQName.Unqualified
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(UnresolvedQName.Unqualified o)
boolean
equals(@Nullable Object obj)
@Nullable String
getPrefix()
Return the prefix of this unresolved QName.int
hashCode()
UnresolvedQName.Unqualified
intern()
Return an interned reference to an equivalent object.static UnresolvedQName.Unqualified
readFrom(DataInput in)
Read an UnqualifiedQName from a DataInput.String
toString()
UnresolvedQName.Qualified
withPrefix(String newPrefix)
Return aUnresolvedQName.Qualified
object bound to specifiedprefix
.void
writeTo(DataOutput out)
Serialize this object into aDataOutput
as a fixed-format stream.-
Methods inherited from class org.opendaylight.yangtools.yang.common.UnresolvedQName
qualified, tryLocalName, unqualified
-
Methods inherited from class org.opendaylight.yangtools.yang.common.AbstractQName
bindTo, getLocalName
-
-
-
-
Method Detail
-
readFrom
public static UnresolvedQName.Unqualified readFrom(DataInput in) throws IOException
Read an UnqualifiedQName from a DataInput. The format is expected to match the output format ofwriteTo(DataOutput)
.- Parameters:
in
- DataInput to read- Returns:
- An UnqualifiedQName instance
- Throws:
IOException
- if I/O error occurs
-
intern
public UnresolvedQName.Unqualified intern()
Description copied from class:AbstractQName
Return an interned reference to an equivalent object.- Specified by:
intern
in classUnresolvedQName
- Returns:
- Interned reference, or this object if it was interned.
-
getPrefix
public @Nullable String getPrefix()
Description copied from class:UnresolvedQName
Return the prefix of this unresolved QName.- Specified by:
getPrefix
in classUnresolvedQName
- Returns:
- This QName's prefix
-
withPrefix
public UnresolvedQName.Qualified withPrefix(String newPrefix)
Description copied from class:UnresolvedQName
Return aUnresolvedQName.Qualified
object bound to specifiedprefix
.- Specified by:
withPrefix
in classUnresolvedQName
- Returns:
- a
UnresolvedQName.Qualified
object bound to specifiedprefix
-
compareTo
public int compareTo(UnresolvedQName.Unqualified o)
- Specified by:
compareTo
in interfaceComparable<UnresolvedQName.Unqualified>
-
writeTo
public void writeTo(DataOutput out) throws IOException
Description copied from interface:WritableObject
Serialize this object into aDataOutput
as a fixed-format stream.- Specified by:
writeTo
in interfaceWritableObject
- Parameters:
out
- Data output- Throws:
IOException
- if an I/O error occurs
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceIdentifier
- Specified by:
hashCode
in classAbstractQName
-
equals
public boolean equals(@Nullable Object obj)
- Specified by:
equals
in interfaceIdentifier
- Specified by:
equals
in classAbstractQName
-
toString
public String toString()
- Specified by:
toString
in interfaceIdentifier
- Specified by:
toString
in classAbstractQName
-
-