|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public static interface AbstractDocument.Content
A sequence of data that can be edited. This is were the actual content
in AbstractDocument
's is stored.
Method Summary | |
---|---|
Position |
createPosition(int offset)
Creates a Position that keeps track of the location at
offset . |
void |
getChars(int where,
int len,
Segment txt)
Fetches a piece of content and stores it in txt . |
String |
getString(int where,
int len)
Returns a piece of content. |
UndoableEdit |
insertString(int where,
String str)
Inserts a string into the content model. |
int |
length()
Returns the length of the content. |
UndoableEdit |
remove(int where,
int nitems)
Removes a piece of content from the content model. |
Method Detail |
---|
Position createPosition(int offset) throws BadLocationException
Position
that keeps track of the location at
offset
.
Position
that keeps track of the location at
offset
.
BadLocationException
int length()
UndoableEdit insertString(int where, String str) throws BadLocationException
where
- the offset at which to insert the stringstr
- the string to be inserted
UndoableEdit
or null
if undo is
not supported by this Content
model
BadLocationException
- if where
is not a valid
location in this Content
modelUndoableEdit remove(int where, int nitems) throws BadLocationException
where
- the offset at which to remove contentnitems
- the number of characters to be removed
UndoableEdit
or null
if undo is
not supported by this Content
model
BadLocationException
- if where
is not a valid
location in this Content
modelString getString(int where, int len) throws BadLocationException
where
- the start offset of the requested fragmentlen
- the length of the requested fragment
BadLocationException
- if offset
or
offset + len
is not a valid
location in this Content
modelvoid getChars(int where, int len, Segment txt) throws BadLocationException
txt
.
where
- the start offset of the requested fragmentlen
- the length of the requested fragmenttxt
- the Segment
where to fragment is stored into
BadLocationException
- if offset
or
offset + len
is not a valid
location in this Content
model
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |