public class CursorBuffer extends java.lang.Object
StringBuffer that also contains the
current cursor position.| Modifier and Type | Field | Description |
|---|---|---|
int |
cursor |
| Constructor | Description |
|---|---|
CursorBuffer() |
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
clearBuffer() |
|
char |
current() |
|
java.lang.StringBuffer |
getBuffer() |
|
boolean |
isOvertyping() |
|
int |
length() |
|
void |
setBuffer(java.lang.StringBuffer buffer) |
|
void |
setOvertyping(boolean b) |
|
java.lang.String |
toString() |
|
void |
write(char c) |
Write the specific character into the buffer, setting the cursor position
ahead one.
|
void |
write(java.lang.String str) |
Insert the specified
String into the buffer, setting the cursor
to the end of the insertion point. |
public int cursor
public CursorBuffer()
public int length()
public char current()
public boolean clearBuffer()
public void write(char c)
c - the character to insertpublic void write(java.lang.String str)
String into the buffer, setting the cursor
to the end of the insertion point.str - the String to insert. Must not be null.public java.lang.String toString()
toString in class java.lang.Objectpublic boolean isOvertyping()
public void setOvertyping(boolean b)
public java.lang.StringBuffer getBuffer()
public void setBuffer(java.lang.StringBuffer buffer)