|
TinyLine v2.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.tinyline.tiny2d.TinyString
The TinyString class represents character strings.
| Field Summary | |
int |
count
The number of chars in this TinyString object. |
char[] |
data
The buffer where the chars of the TinyString are stored. |
| Constructor Summary | |
TinyString(char[] ac)
Allocates a new TinyString, so that it has the
sequence of characters from the character array argument. |
|
TinyString(char[] ac,
int off,
int len)
Allocates a new TinyString, so that it has the
sequence of characters from the character subarray argument. |
|
| Method Summary | |
static int |
compareTo(char[] v1,
int offset1,
int len1,
char[] v2,
int offset2,
int len2)
Compares two char arrays lexicographically. |
boolean |
equals(java.lang.Object obj)
Compares this string to the specified object. |
int |
hashCode()
Returns a hashcode for this string. |
int |
indexOf(int ch,
int i)
Returns the index within this string of the first occurrence of the specified character, starting the search at the specified index. |
int |
lastIndexOf(int ch,
int i)
Returns the index within this string of the last occurrence of the specified character, searching backward starting at the specified index. |
| Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public char[] data
public int count
| Constructor Detail |
public TinyString(char[] ac)
TinyString, so that it has the
sequence of characters from the character array argument.
The content of the character array 'ac' is copied.
ac - the initial value of the string.
public TinyString(char[] ac,
int off,
int len)
TinyString, so that it has the
sequence of characters from the character subarray argument.
The content of the character subarray 'ac' is copied.
ac - array that is the source of characters.off - the initial offset.len - the length.| Method Detail |
public int indexOf(int ch,
int i)
ch - a character.i - the index to start the search from.
fromIndex, or -1
if the character does not occur.
public int lastIndexOf(int ch,
int i)
ch - a character.i - the index to start the search from.
fromIndex, or -1
if the character does not occur before that point.public boolean equals(java.lang.Object obj)
true if and only if the argument is not
null and is a TinyString object that represents
the same sequence of characters as this object.
obj - the object to compare this String
against.
true if the TinyString are equal;
false otherwise.public int hashCode()
public static int compareTo(char[] v1,
int offset1,
int len1,
char[] v2,
int offset2,
int len2)
0 if the argument string is equal to
this string; a value less than 0 if this string
is lexicographically less than the string argument; and a
value greater than 0 if this string is
lexicographically greater than the string argument.
|
TinyLine v2.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||