protected void error(String message,int position,String context){
  throw new IllegalArgumentException("Parse error at position (" + position + "): "+ message+ "\n"+ context.substring(0,position)+ " -here- "+ context.substring(position));
}

protected void error ( String message , int position , String context ) { throw new IllegalArgumentException ( "Parse error at position (" + position + "): " + message + "\n" + context . substring ( 0 , position ) + " -here- " + context . substring ( position ) ) ; }
throws an illegalargumentexception representing a syntax error in the rule description . the exception ' s message contains some debugging information .
