com.fasterxml.aalto.in
Class PNameN

java.lang.Object
  extended by com.fasterxml.aalto.in.PName
      extended by com.fasterxml.aalto.in.ByteBasedPName
          extended by com.fasterxml.aalto.in.PNameN

public final class PNameN
extends ByteBasedPName

General implementation of PName to be used with longer names (ones that consist of more than 8 bytes).

The reason for such specialized classes is mostly space efficiency; and to a lesser degree performance. Both are achieved for short Strings by avoiding another level of indirection (via quad arrays)


Field Summary
 
Fields inherited from class com.fasterxml.aalto.in.ByteBasedPName
mHash
 
Fields inherited from class com.fasterxml.aalto.in.PName
_localName, _namespaceBinding, _prefix, _prefixedName
 
Method Summary
 PName createBoundName(com.fasterxml.aalto.in.NsBinding nsb)
           
 boolean equals(int[] quads, int qlen)
           
 boolean equals(int quad1, int quad2)
           
 int getFirstQuad()
           
 int getLastQuad()
           
 int getQuad(int index)
           
 int sizeInQuads()
           
 
Methods inherited from class com.fasterxml.aalto.in.ByteBasedPName
hashCode
 
Methods inherited from class com.fasterxml.aalto.in.PName
boundEquals, boundEquals, boundHashCode, boundHashCode, constructQName, constructQName, equals, getLocalName, getNsBinding, getNsUri, getPrefix, getPrefixedName, hasPrefix, hasPrefixedName, isBound, needsBinding, toString, unboundEquals, unboundHashCode
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

createBoundName

public PName createBoundName(com.fasterxml.aalto.in.NsBinding nsb)
Specified by:
createBoundName in class PName

equals

public boolean equals(int quad1,
                      int quad2)
Specified by:
equals in class ByteBasedPName

equals

public boolean equals(int[] quads,
                      int qlen)
Specified by:
equals in class ByteBasedPName

getFirstQuad

public int getFirstQuad()
Specified by:
getFirstQuad in class ByteBasedPName

getLastQuad

public int getLastQuad()
Specified by:
getLastQuad in class PName

getQuad

public int getQuad(int index)
Specified by:
getQuad in class ByteBasedPName

sizeInQuads

public int sizeInQuads()
Specified by:
sizeInQuads in class ByteBasedPName


Copyright © 2012 Fasterxml.com. All Rights Reserved.