public class BufferContent extends SwtCharBuffer implements CharSeq
lineOffsets data, empty COPY_ON_WRITE, GAP_FLAG, info, MAX_GAP_SIZE, READ_ONLY_FLAG, SHARED_FLAG, SUBRANGE_FLAG, VERY_SIMPLE_FLAG noInts ATTRIBUTE_VALUE, BOOLEAN_VALUE, CDATA_VALUE, CHAR_VALUE, COMMENT_VALUE, DOCUMENT_VALUE, DOUBLE_VALUE, ELEMENT_VALUE, EOF_VALUE, eofValue, FLOAT_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 and Description |
|---|
BufferContent () |
BufferContent (int initialSize) |
| Modifier and Type | Method and Description |
|---|---|
void |
addTextChangeListener (TextChangeListener textChangeListener) |
int |
getCharCount () |
java.lang.String |
getLine (int lineIndex) |
int |
getLineAtOffset (int pos) |
int |
getLineCount () |
java.lang.String |
getLineDelimiter () |
int |
getOffsetAtLine (int lineIndex) |
java.lang.String |
getTextRange (int start,
int length) |
void |
insertFile (java.io.Reader in,
int pos) |
int |
lineStartPos (int pos) |
void |
removeTextChangeListener (TextChangeListener textChangeListener) |
void |
replaceTextRange (int start,
int length,
java.lang.String newText) |
void |
save (java.io.Writer out) |
void |
setCharAt (int index,
char value) |
void |
setText (java.lang.String newText) |
java.lang.CharSequence |
subSequence (int start,
int end) |
void |
writeTo (java.lang.Appendable dest) |
void |
writeTo (int start,
int count,
java.lang.Appendable dest)
Append a specified subsequence to an
Appendable. |
charAt, delete, gapReserve, getChars, insert, length, offset2pos, pos2offset, printable, shiftGap, show, toString addAll, addAllStrings, alloc, append, append, append, append, appendCharacter, characterAt, consumePosRange, copy, createPos, createRelativePos, effectiveIndex, equals, get, getElementKind, getRaw, getTag, indexOf, insert, insert, insertRepeated, lastIndexOf, newInstance, nextIndex, prepend, prepend, prependCharacter, replace, replace, replace, set, setCharacterAt, setCharAtBuffer, setRaw, shift, size, substring, toCharArray clearBuffer, compareTo, compareTo, compareTo, copyBuffer, ensureBufferLength, equals, getBuffer, getBufferLength, getCharRaw, hashCode, openReader, openReader, setBuffer add, add, addPos, addSpace, asImmutable, checkCanWrite, doCopyOnWrite, fill, forEach, gapReserveGeneric, getGapEnd, getGapSize, getGapStart, getOffsetBits, getRowMajor, getSegment, getSegment, getSegmentReadOnly, getSizeBits, isAfterPos, isGapBuffer, isReadOnly, isSubRange, isVerySimple, readExternal, setGapBounds, setGapBounds, setInfoField, setReadOnly, toDataArray, writeExternal addAll, addAll, badRank, boundedHash, checkRank, clear, compare, compare, compare, consume, consume, consumeNext, contains, containsAll, copyPos, effectiveIndex, effectiveIndex, effectiveIndex, effectiveIndex, elements, endPos, equals, fill, fillPosRange, firstAttributePos, firstChildPos, firstChildPos, fromEndIndex, get, get, get, get, getAttribute, getAttributeLength, getBooleanRaw, getByteRaw, getContainingSequenceSize, getDoubleRaw, getFloatRaw, getIndexDifference, getInt, getInt, getInt, getInt, getInt, getIntRaw, getIterator, getIterator, getIteratorAtPos, getLongRaw, getLowBound, getNextKind, getNextTypeName, getNextTypeObject, getPosNext, getPosPrevious, getShortRaw, getSize, getSize, gotoAttributesStart, gotoChildrenStart, gotoParent, hasNext, hasPrevious, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, nextIndex, nextMatching, nextPos, parentPos, previousPos, rank, releasePos, remove, remove, removeAll, removePos, removePosRange, retainAll, set, setAt, setPosNext, setPosPrevious, stableCompare, startPos, subList, subSequence, subSequencePos, toArray, toArray, toString, unsupported, unsupportedException clone, finalize, getClass, notify, notifyAll, wait, wait, waitcharAt, getChars, length, setCharacterAt, toString chars, codePointsadd, add, addAll, addAll, clear, contains, containsAll, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, replaceAll, retainAll, sort, spliterator, subList, toArray, toArrayparallelStream, removeIf, streamforEachconsume boundedHash effectiveIndex, effectiveIndex, effectiveIndex, effectiveIndex, get, get, get, get, getBooleanRaw, getByteRaw, getDoubleRaw, getFloatRaw, getInt, getInt, getInt, getInt, getInt, getIntRaw, getLongRaw, getLowBound, getShortRaw, getSize, getSize, isEmpty, rank, set public BufferContent()
public BufferContent(int initialSize)
initialSize - public void addTextChangeListener(TextChangeListener textChangeListener)
public void removeTextChangeListener(TextChangeListener textChangeListener)
public int getCharCount()
public java.lang.String getLine(int lineIndex)
public int getLineAtOffset(int pos)
public int getLineCount()
public java.lang.String getLineDelimiter()
public int getOffsetAtLine(int lineIndex)
public java.lang.String getTextRange(int start, int length)
public void replaceTextRange(int start, int length, java.lang.String newText)
public void setText(java.lang.String newText)
public int lineStartPos(int pos)
public void insertFile(java.io.Reader in, int pos) throws java.io.IOException
java.io.IOExceptionpublic void setCharAt(int index, char value)
public java.lang.CharSequence subSequence(int start, int end)
subSequence in interface java.lang.CharSequencesubSequence in class SwtCharBuffer 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.public void writeTo(java.lang.Appendable dest) throws java.io.IOException
public void save(java.io.Writer out) throws java.io.IOException
out - java.io.IOException