java.lang.Object
dev.civl.abc.token.IF.TokenUtils
Utility class providing static methods dealing with Token objects.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetShortFilename(org.antlr.runtime.Token token, boolean abbreviated) Computes a short version of the file name from a token's source file.static org.antlr.runtime.TokenSource
-
Field Details
-
eofToken
public static final org.antlr.runtime.Token eofToken
-
-
Constructor Details
-
TokenUtils
public TokenUtils()
-
-
Method Details
-
getShortFilename
Computes a short version of the file name from a token's source file.- Parameters:
token- a tokenabbreviated- true iff the result is an abbreviated file name, i.e., shorter file name, which is calculated by the static hash map.- Returns:
- the short file name
-
makeTokenSourceFromList
-