Class ErrorProneTokens
java.lang.Object
com.google.errorprone.util.ErrorProneTokens
A utility for tokenizing and preserving comments.
-
Constructor Summary
ConstructorDescriptionErrorProneTokens
(String source, int offset, com.sun.tools.javac.util.Context context) ErrorProneTokens
(String source, com.sun.tools.javac.util.Context context) -
Method Summary
Modifier and TypeMethodDescriptioncom.sun.tools.javac.util.Position.LineMap
com.google.common.collect.ImmutableList
<ErrorProneToken> static com.google.common.collect.ImmutableList
<ErrorProneToken> Returns the tokens for the given source text, including comments, indicating the offset of the source within the overall file.static com.google.common.collect.ImmutableList
<ErrorProneToken> Returns the tokens for the given source text, including comments.
-
Constructor Details
-
ErrorProneTokens
-
ErrorProneTokens
-
-
Method Details
-
getLineMap
public com.sun.tools.javac.util.Position.LineMap getLineMap() -
getTokens
-
getTokens
public static com.google.common.collect.ImmutableList<ErrorProneToken> getTokens(String source, com.sun.tools.javac.util.Context context) Returns the tokens for the given source text, including comments. -
getTokens
public static com.google.common.collect.ImmutableList<ErrorProneToken> getTokens(String source, int offset, com.sun.tools.javac.util.Context context) Returns the tokens for the given source text, including comments, indicating the offset of the source within the overall file.
-