Java Code Examples for org.antlr.runtime.CharStream#getSourceName()

The following examples show how to use org.antlr.runtime.CharStream#getSourceName() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 2
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
CharStream input = t.getInputStream();
String srcName = null;
if ( input!=null ) {
	srcName = input.getSourceName();
	if ( srcName!=null ) srcName = Misc.getFileName(srcName);
}
listener.compileTimeError(
          new STCompiletimeMessage(error,srcName,templateToken,t,null,t.getText())
      );
  }
 
Example 3
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 4
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 5
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 6
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 7
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 8
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 9
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 10
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 11
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 12
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 13
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 14
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 15
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 16
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}
 
Example 17
Source File: ErrorManager.java    From codebuff with BSD 2-Clause "Simplified" License 5 votes vote down vote up
public void compileTimeError(ErrorType error, Token templateToken, Token t) {
    CharStream input = t.getInputStream();
    String srcName = null;
    if ( input!=null ) {
        srcName = input.getSourceName();
        if ( srcName!=null ) srcName = Misc.getFileName(srcName);
    }
    listener.compileTimeError(new STCompiletimeMessage(error, srcName, templateToken, t, null, t.getText()));
}