org.nlogo.nvm
Class DefaultCompilerServices
java.lang.Object
org.nlogo.nvm.DefaultCompilerServices
- All Implemented Interfaces:
- org.nlogo.api.CompilerServices
public class DefaultCompilerServices
- extends Object
- implements org.nlogo.api.CompilerServices
DefaultCompilerServices
public DefaultCompilerServices(CompilerInterface compiler)
autoConvert
public String autoConvert(String source,
boolean subprogram,
boolean reporter,
String modelVersion)
- Specified by:
autoConvert
in interface org.nlogo.api.CompilerServices
readNumberFromString
public Object readNumberFromString(String source)
throws CompilerException
- Specified by:
readNumberFromString
in interface org.nlogo.api.CompilerServices
- Throws:
CompilerException
checkReporterSyntax
public void checkReporterSyntax(String source)
throws CompilerException
- Specified by:
checkReporterSyntax
in interface org.nlogo.api.CompilerServices
- Throws:
CompilerException
checkCommandSyntax
public void checkCommandSyntax(String source)
throws CompilerException
- Specified by:
checkCommandSyntax
in interface org.nlogo.api.CompilerServices
- Throws:
CompilerException
readFromString
public Object readFromString(String source)
throws CompilerException
- Specified by:
readFromString
in interface org.nlogo.api.CompilerServices
- Throws:
CompilerException
isValidIdentifier
public boolean isValidIdentifier(String s)
- Specified by:
isValidIdentifier
in interface org.nlogo.api.CompilerServices
tokenizeForColorization
public org.nlogo.api.Token[] tokenizeForColorization(String source)
- Specified by:
tokenizeForColorization
in interface org.nlogo.api.CompilerServices
getTokenAtPosition
public org.nlogo.api.Token getTokenAtPosition(String source,
int pos)
- Specified by:
getTokenAtPosition
in interface org.nlogo.api.CompilerServices
findProcedurePositions
public Map<String,List<Object>> findProcedurePositions(String source)
- Specified by:
findProcedurePositions
in interface org.nlogo.api.CompilerServices