public class CheckstyleApiFixer
extends java.lang.Object
Constructor and Description |
---|
CheckstyleApiFixer(com.puppycrawl.tools.checkstyle.api.AbstractCheck pCheck)
Constructor.
|
CheckstyleApiFixer(com.puppycrawl.tools.checkstyle.api.AbstractCheck pCheck,
java.lang.String pCurrentFileNameMockFile)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
java.io.File |
getCurrentFileName()
Wrapper for
FileContents.getFileName() (Checkstyle issue #1205). |
java.lang.String |
getTokenName(int pTokenId)
Returns the name of a token for a given ID.
|
public CheckstyleApiFixer(@Nonnull com.puppycrawl.tools.checkstyle.api.AbstractCheck pCheck)
pCheck
- the check for which this instance of the API fixer shall runpublic CheckstyleApiFixer(@Nonnull com.puppycrawl.tools.checkstyle.api.AbstractCheck pCheck, @Nullable java.lang.String pCurrentFileNameMockFile)
pCheck
- the check for which this instance of the API fixer shall runpCurrentFileNameMockFile
- file to use as result of getCurrentFileName()
in unit tests@CheckForNull public java.io.File getCurrentFileName()
FileContents.getFileName()
(Checkstyle issue #1205).java.lang.UnsupportedOperationException
- no known variant of FileContents.getFileName()
could be found@Nonnull public java.lang.String getTokenName(int pTokenId)
pTokenId
- the ID of the token name to getjava.lang.UnsupportedOperationException
- no known variant of getTokenName()
could be found