org.eclipse.jdt.internal.formatter.comment
Class CommentRange
java.lang.Object
org.eclipse.jface.text.Position
org.eclipse.jdt.internal.formatter.comment.CommentRange
- All Implemented Interfaces:
- ICommentAttributes, IHtmlTagDelimiters
public class CommentRange
- extends org.eclipse.jface.text.Position
- implements ICommentAttributes, IHtmlTagDelimiters
Range in a comment region in comment region coordinates.
- Since:
- 3.0
Fields inherited from class org.eclipse.jface.text.Position |
isDeleted, length, offset |
Fields inherited from interface org.eclipse.jdt.internal.formatter.comment.ICommentAttributes |
COMMENT_BLANKLINE, COMMENT_BREAK, COMMENT_CLOSE, COMMENT_CODE, COMMENT_FIRST_TOKEN, COMMENT_HTML, COMMENT_IMMUTABLE, COMMENT_NEWLINE, COMMENT_OPEN, COMMENT_PARAGRAPH, COMMENT_PARAMETER, COMMENT_ROOT, COMMENT_SEPARATOR, COMMENT_STARTS_WITH_RANGE_DELIMITER |
Constructor Summary |
CommentRange(int position,
int count)
Creates a new comment range. |
Method Summary |
void |
move(int delta)
Moves this comment range. |
java.lang.String |
toString()
|
void |
trimBegin(int delta)
Trims this comment range at the beginning. |
void |
trimEnd(int delta)
Trims this comment range at the end. |
Methods inherited from class org.eclipse.jface.text.Position |
delete, equals, getLength, getOffset, hashCode, includes, isDeleted, overlapsWith, setLength, setOffset, undelete |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
CommentRange
public CommentRange(int position,
int count)
- Creates a new comment range.
- Parameters:
position
- offset of the rangecount
- length of the range
move
public final void move(int delta)
- Moves this comment range.
- Parameters:
delta
- the delta to move the range
trimBegin
public final void trimBegin(int delta)
- Trims this comment range at the beginning.
- Parameters:
delta
- amount to trim the range
trimEnd
public final void trimEnd(int delta)
- Trims this comment range at the end.
- Parameters:
delta
- amount to trim the range
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object