public class CursorBuffer extends Object
StringBuffer that also contains the
current cursor position.| Modifier and Type | Field and Description |
|---|---|
int |
cursor |
| Constructor and Description |
|---|
CursorBuffer() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
clearBuffer() |
char |
current() |
StringBuffer |
getBuffer() |
boolean |
isOvertyping() |
int |
length() |
void |
setBuffer(StringBuffer buffer) |
void |
setOvertyping(boolean b) |
String |
toString() |
void |
write(char c)
Write the specific character into the buffer, setting the cursor position
ahead one.
|
void |
write(String str)
Insert the specified
String into the buffer, setting the cursor
to the end of the insertion point. |
public int length()
public char current()
public boolean clearBuffer()
public void write(char c)
c - the character to insertpublic void write(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 boolean isOvertyping()
public void setOvertyping(boolean b)
public StringBuffer getBuffer()
public void setBuffer(StringBuffer buffer)
Copyright © 2025. All rights reserved.