public abstract static class DocumentLine.Set extends Line.Set
Line.Set.
Defines
ways to obtain a line set for documents following
NetBeans conventions.| Constructor and Description |
|---|
Set(StyledDocument doc)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected abstract Line |
createLine(int offset)
Creates a
Line for a given offset. |
Line |
getCurrent(int line)
Find line object representing the line in current document.
|
List<? extends Line> |
getLines()
Returns a set of line objects sorted by their
line numbers.
|
Line |
getOriginal(int line)
Find line object in the line set corresponding to original line number.
|
int |
getOriginalLineNumber(Line line)
Finds an original line number for given line in this line set.
|
public Set(StyledDocument doc)
doc - document to work onpublic List<? extends Line> getLines()
Line.Setpublic Line getOriginal(int line) throws IndexOutOfBoundsException
Line.SetgetOriginal in class Line.Setline - number of the line (starting at 0)IndexOutOfBoundsException - if line is an invalid index for the original set of linespublic int getOriginalLineNumber(Line line)
Line.SetgetOriginalLineNumber in class Line.Setline - the line to look forpublic Line getCurrent(int line) throws IndexOutOfBoundsException
Line.SetgetCurrent in class Line.Setline - number of the line in current state of the document (starting at 0)IndexOutOfBoundsException - if line is an invalid index for the original set of linesBuilt on August 24 2014. | Portions Copyright 1997-2014 Sun Microsystems, Inc. All rights reserved.