Package org.eclipse.jdt.core.dom.rewrite
Class TargetSourceRangeComputer.SourceRange
java.lang.Object
org.eclipse.jdt.core.dom.rewrite.TargetSourceRangeComputer.SourceRange
- Enclosing class:
TargetSourceRangeComputer
Reified source range. Instances are "value" object
(cannot be modified).
- Since:
- 3.1
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintReturns the source length.intReturns the start position.
-
Constructor Details
-
SourceRange
public SourceRange(int startPosition, int length) Creates a new source range.- Parameters:
startPosition- the 0-based character index, or-1if no source position information is knownlength- the (possibly 0) length, or0if no source position information is known
-
-
Method Details
-
getStartPosition
public int getStartPosition()Returns the start position.- Returns:
- the 0-based character index, or
-1if no source position information is known
-
getLength
public int getLength()Returns the source length.- Returns:
- a (possibly 0) length, or
0if no source position information is known
-