public abstract class Name extends Object implements Name
This is NOT part of any supported API. If you write code that depends on this, you do so at your own risk. This code and its internal interfaces are subject to change or deletion without notice.
Modifier and Type | Class and Description |
---|---|
static class |
Name.Table
An abstraction for the hash table used to create unique Name instances.
|
Modifier and Type | Field and Description |
---|---|
Name.Table |
table |
Modifier | Constructor and Description |
---|---|
protected |
Name(Name.Table table) |
Modifier and Type | Method and Description |
---|---|
Name |
append(char c,
Name n)
Return the concatenation of this name, the given ASCII
character, and name `n'.
|
Name |
append(Name n)
Return the concatenation of this name and name `n'.
|
char |
charAt(int index) |
int |
compareTo(Name other)
An arbitrary but consistent complete order among all Names.
|
boolean |
contentEquals(CharSequence cs) |
abstract byte[] |
getByteArray()
Get the underlying byte array for this name.
|
abstract byte |
getByteAt(int i)
Returns i'th byte of this name.
|
abstract int |
getByteLength()
Get the length (in bytes) of this name.
|
abstract int |
getByteOffset()
Get the start offset of this name within its byte array.
|
void |
getBytes(byte[] cs,
int start)
Copy all bytes of this name to buffer cs, starting at start.
|
abstract int |
getIndex() |
boolean |
isEmpty()
Return true if this is the empty name.
|
int |
lastIndexOf(byte b)
Returns last occurrence of byte b in this name, -1 if not found.
|
int |
length() |
boolean |
startsWith(Name prefix)
Does this name start with prefix?
|
Name |
subName(int start,
int end)
Returns the sub-name starting at position start, up to and
excluding position end.
|
CharSequence |
subSequence(int start,
int end) |
String |
toString()
Return the string representation of this name.
|
byte[] |
toUtf()
Return the Utf8 representation of this name.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
chars, codePoints
public final Name.Table table
protected Name(Name.Table table)
public boolean contentEquals(CharSequence cs)
contentEquals
in interface Name
public int length()
length
in interface CharSequence
public char charAt(int index)
charAt
in interface CharSequence
public CharSequence subSequence(int start, int end)
subSequence
in interface CharSequence
public Name append(char c, Name n)
public int compareTo(Name other)
public boolean isEmpty()
public int lastIndexOf(byte b)
public boolean startsWith(Name prefix)
public Name subName(int start, int end)
public String toString()
toString
in interface CharSequence
toString
in class Object
public byte[] toUtf()
public abstract int getIndex()
public abstract int getByteLength()
public abstract byte getByteAt(int i)
public void getBytes(byte[] cs, int start)
public abstract byte[] getByteArray()
public abstract int getByteOffset()
Copyright © 2017 earcam. All rights reserved.