|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object gnu.lists.AbstractSequence gnu.jemacs.buffer.Buffer
public abstract class Buffer
Field Summary | |
---|---|
EKeymap[] |
activeKeymaps
|
static java.util.Hashtable |
buffers
Map buffer names to buffers. |
static java.util.Hashtable |
fileBuffers
Map file names to buffer.s |
Marker |
markMarker
|
Marker |
pointMarker
|
Fields inherited from interface gnu.lists.Sequence |
---|
ATTRIBUTE_VALUE, BOOLEAN_VALUE, CDATA_VALUE, CHAR_VALUE, COMMENT_VALUE, DOCUMENT_VALUE, DOUBLE_VALUE, EOF_VALUE, eofValue, FLOAT_VALUE, GROUP_VALUE, INT_S16_VALUE, INT_S32_VALUE, INT_S64_VALUE, INT_S8_VALUE, INT_U16_VALUE, INT_U32_VALUE, INT_U64_VALUE, INT_U8_VALUE, OBJECT_VALUE, PRIM_VALUE, PROCESSING_INSTRUCTION_VALUE, TEXT_BYTE_VALUE |
Constructor Summary | |
---|---|
Buffer(java.lang.String name)
|
Method Summary | |
---|---|
void |
backwardChar(int i)
|
char |
charAt(int index)
|
int |
charWidth(char ch,
int column)
|
int |
checkMark()
|
static Buffer |
coerceBuffer(java.lang.Object buf)
|
void |
consume(int start,
int count,
Consumer out)
|
int |
countColumns(char[] chars,
int start,
int count,
int initial)
|
int |
currentColumn()
|
int |
currentColumn(int offset)
Return the column number at a specified offset. |
EWindow |
display(boolean notThisWindow,
EFrame frame)
|
void |
fill(char value)
Set all the elements to a given character. |
void |
fill(int fromIndex,
int toIndex,
char value)
|
static Buffer |
findFile(java.lang.String fname)
|
void |
forwardChar(int i)
|
int |
forwardLine(int lines)
|
long |
forwardLine(int lines,
int start)
Find the position a give number of lines forward or backward. |
static java.lang.String |
generateNewBufferName(java.lang.String start)
|
static Buffer |
getBuffer(java.lang.String name)
|
void |
getChars(int srcBegin,
int srcEnd,
char[] dst,
int dstBegin)
Copy characters into a destination buffer. |
static Buffer |
getCurrent()
|
int |
getDot()
|
java.lang.String |
getFileName()
|
abstract int |
getLength()
|
EKeymap |
getLocalKeymap()
|
Marker |
getMarkMarker(boolean force)
|
java.lang.String |
getName()
|
int |
getPoint()
|
Marker |
getPointMarker(boolean share)
|
abstract CharSeq |
getStringContent()
|
void |
insert(char[] chars,
int offset,
int count,
java.lang.Object style,
int ipos)
Insert character with given style at position pair. |
void |
insert(char ch,
int count)
Insert count copies of ch at point. |
void |
insert(char ch,
int count,
java.lang.Object style)
Insert count copies of ch at point. |
void |
insert(java.lang.Object value,
java.lang.Object style)
|
void |
insert(java.lang.String string,
java.lang.Object style)
|
abstract void |
insert(java.lang.String string,
java.lang.Object style,
int ipos)
Insert string with given style at position pair. |
void |
insertAll(java.lang.Object[] values,
java.lang.Object style)
|
abstract void |
insertFile(java.io.Reader in)
|
void |
insertFile(java.lang.String filename)
|
abstract void |
invoke(java.lang.Runnable doRun)
This is intended for Runnable's that may affect the state of the buffer. |
int |
length()
Get length of string, in characters. |
int |
lineStartOffset()
|
abstract int |
lineStartOffset(int offset)
|
static void |
makeBufferLocal(java.lang.Object symbol,
boolean all)
|
abstract int |
maxDot()
|
int |
minDot()
|
int |
moveToColumn(int column,
boolean force)
|
abstract InPort |
openReader(int start,
int count)
|
int |
positionToOffset(java.lang.Object position)
Convert an Emacs position (Marker, or 1-origin integer) to a (0-origin) buffer offset. |
abstract void |
redrawModeline()
|
abstract void |
removeAll()
|
void |
removeChar(int count)
|
abstract void |
restorePointMark(long pointMark)
|
void |
save()
|
abstract void |
save(java.io.Writer out)
|
abstract long |
savePointMark()
|
abstract long |
scan(char target,
int start,
int end,
int count,
boolean allowQuit)
Search in BUF for COUNT instances of the character TARGET between START and END. |
void |
setCharAt(int index,
char ch)
|
static void |
setCurrent(Buffer buffer)
|
void |
setDot(int i)
|
void |
setFileName(java.lang.String fname)
|
void |
setLocalKeymap(EKeymap map)
|
void |
setPoint(int i)
|
java.lang.CharSequence |
subSequence(int start,
int end)
|
java.lang.String |
toString()
|
void |
writeTo(java.lang.Appendable dest)
|
void |
writeTo(int start,
int count,
java.lang.Appendable dest)
Append a specified subsequence to an Appendable . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface gnu.lists.Sequence |
---|
elements, fill, get, isEmpty, size |
Methods inherited from interface java.util.List |
---|
add, add, addAll, addAll, clear, contains, containsAll, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, subList, toArray, toArray |
Methods inherited from interface gnu.lists.Consumable |
---|
consume |
Field Detail |
---|
public Marker pointMarker
public Marker markMarker
public static java.util.Hashtable buffers
public static java.util.Hashtable fileBuffers
public EKeymap[] activeKeymaps
Constructor Detail |
---|
public Buffer(java.lang.String name)
Method Detail |
---|
public java.lang.String getName()
public java.lang.String getFileName()
public void setFileName(java.lang.String fname)
public abstract CharSeq getStringContent()
public char charAt(int index)
charAt
in interface CharSeq
charAt
in interface java.lang.CharSequence
CharSeq.charAt(int)
public void setCharAt(int index, char ch)
setCharAt
in interface CharSeq
CharSeq.setCharAt(int, char)
public void fill(char value)
CharSeq
fill
in interface CharSeq
CharSeq.fill(char)
public void fill(int fromIndex, int toIndex, char value)
fill
in interface CharSeq
CharSeq.fill(int, int, char)
public void getChars(int srcBegin, int srcEnd, char[] dst, int dstBegin)
CharSeq
getChars
in interface CharSeq
CharSeq.getChars(int, int, char[], int)
public java.lang.CharSequence subSequence(int start, int end)
subSequence
in interface CharSeq
subSequence
in interface java.lang.CharSequence
public void writeTo(int start, int count, java.lang.Appendable dest) throws java.io.IOException
CharSeq
Appendable
.
An allowable implementation is:
dest.append(this, start, start+count)
.
Hence implementors of Appendable
should avoid calling
writeTo
- though they can call getChars
.
writeTo
in interface CharSeq
java.io.IOException
CharSeq.writeTo(int, int, Appendable)
public void writeTo(java.lang.Appendable dest) throws java.io.IOException
writeTo
in interface CharSeq
java.io.IOException
public void consume(int start, int count, Consumer out)
consume
in interface CharSeq
CharSeq.consume(int, int, gnu.lists.Consumer)
public static Buffer findFile(java.lang.String fname)
public static Buffer getBuffer(java.lang.String name)
public static Buffer coerceBuffer(java.lang.Object buf)
public static java.lang.String generateNewBufferName(java.lang.String start)
public abstract void redrawModeline()
public int checkMark()
public static Buffer getCurrent()
public static void setCurrent(Buffer buffer)
public int getDot()
public int getPoint()
public void setDot(int i)
public final void setPoint(int i)
public int minDot()
public abstract int getLength()
public final int length()
CharSeq
length
in interface CharSeq
length
in interface java.lang.CharSequence
public abstract int maxDot()
public void forwardChar(int i)
public void backwardChar(int i)
public java.lang.String toString()
toString
in interface CharSeq
toString
in interface java.lang.CharSequence
toString
in class AbstractSequence
public abstract void insert(java.lang.String string, java.lang.Object style, int ipos)
public void insert(char[] chars, int offset, int count, java.lang.Object style, int ipos)
public void insertAll(java.lang.Object[] values, java.lang.Object style)
public void insert(java.lang.String string, java.lang.Object style)
public void insert(java.lang.Object value, java.lang.Object style)
public void insert(char ch, int count)
public void insert(char ch, int count, java.lang.Object style)
public void removeChar(int count)
public abstract void removeAll()
public Marker getPointMarker(boolean share)
public Marker getMarkMarker(boolean force)
public int positionToOffset(java.lang.Object position)
public abstract void insertFile(java.io.Reader in) throws java.lang.Exception
java.lang.Exception
public abstract void save(java.io.Writer out) throws java.lang.Exception
java.lang.Exception
public void save()
public void insertFile(java.lang.String filename)
public int charWidth(char ch, int column)
public int countColumns(char[] chars, int start, int count, int initial)
public int currentColumn()
public int currentColumn(int offset)
public int moveToColumn(int column, boolean force)
public abstract int lineStartOffset(int offset)
public int lineStartOffset()
public abstract long scan(char target, int start, int end, int count, boolean allowQuit)
public final long forwardLine(int lines, int start)
lines
- number of lines forward (or backward if negative)start
- initial position (buffer offset)
public int forwardLine(int lines)
public EWindow display(boolean notThisWindow, EFrame frame)
public static void makeBufferLocal(java.lang.Object symbol, boolean all)
all
- true if make-variable-buffer-local,
false if make-local-variable FIXMEpublic EKeymap getLocalKeymap()
public void setLocalKeymap(EKeymap map)
public abstract InPort openReader(int start, int count)
public abstract long savePointMark()
public abstract void restorePointMark(long pointMark)
public abstract void invoke(java.lang.Runnable doRun)
doRun
-
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |