Class StandardTokeniser
- java.lang.Object
-
- uk.ac.warwick.dcs.sherlock.module.model.base.preprocessing.StandardTokeniser
-
- All Implemented Interfaces:
ITokenStringifier
public class StandardTokeniser extends java.lang.Object implements ITokenStringifier
-
-
Constructor Summary
Constructors Constructor Description StandardTokeniser()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static int
preserveCommentLines(java.util.List<IndexedString> output, java.lang.StringBuilder active, int lineCount, org.antlr.v4.runtime.Token t, org.antlr.v4.runtime.Vocabulary vocab)
java.util.List<IndexedString>
processTokens(java.util.List<? extends org.antlr.v4.runtime.Token> tokens, org.antlr.v4.runtime.Vocabulary vocab)
Tokenises a file in the form of a list of tokens
-
-
-
Method Detail
-
processTokens
public java.util.List<IndexedString> processTokens(java.util.List<? extends org.antlr.v4.runtime.Token> tokens, org.antlr.v4.runtime.Vocabulary vocab)
Tokenises a file in the form of a list of tokens- Specified by:
processTokens
in interfaceITokenStringifier
- Parameters:
tokens
- the file as a list of tokensvocab
- the lexer vocab- Returns:
- indexed lines of the file, tokenised
-
preserveCommentLines
public static int preserveCommentLines(java.util.List<IndexedString> output, java.lang.StringBuilder active, int lineCount, org.antlr.v4.runtime.Token t, org.antlr.v4.runtime.Vocabulary vocab)
-
-