/* Generated By:JavaCC: Do not edit this line. SimpleCharStream.java Version 7.0 */ /* JavaCCOptions:STATIC=false,SUPPORT_CLASS_VISIBILITY_PUBLIC=true */ package org.apache.el.parser;
/** * An implementation of interface CharStream, where the stream is assumed to * contain only ASCII characters (without unicode processing).
*/
@SuppressWarnings("all") // Ignore warnings in generated code publicclass SimpleCharStream
{ /** Whether parser is static. */ publicstaticfinalboolean staticFlag = false; int bufsize; int available; int tokenBegin; /** Position in buffer. */ publicint bufpos = -1; protectedint bufline[]; protectedint bufcolumn[];
/** Constructor. */ public SimpleCharStream(java.io.Reader dstream, int startline, int startcolumn, int buffersize)
{
inputStream = dstream;
line = startline;
column = startcolumn - 1;
/** Reinitialise. */ publicvoid ReInit(java.io.Reader dstream, int startline, int startcolumn)
{
ReInit(dstream, startline, startcolumn, 4096);
}
/** Reinitialise. */ publicvoid ReInit(java.io.Reader dstream)
{
ReInit(dstream, 1, 1, 4096);
} /** Constructor. */ public SimpleCharStream(java.io.InputStream dstream, String encoding, int startline, int startcolumn, int buffersize) throws java.io.UnsupportedEncodingException
{ this(encoding == null ? new java.io.InputStreamReader(dstream) : new java.io.InputStreamReader(dstream, encoding), startline, startcolumn, buffersize);
}
/** Constructor. */ public SimpleCharStream(java.io.InputStream dstream, int startline, int startcolumn, int buffersize)
{ this(new java.io.InputStreamReader(dstream), startline, startcolumn, buffersize);
}
/** Constructor. */ public SimpleCharStream(java.io.InputStream dstream, String encoding, int startline, int startcolumn) throws java.io.UnsupportedEncodingException
{ this(dstream, encoding, startline, startcolumn, 4096);
}
/** Constructor. */ public SimpleCharStream(java.io.InputStream dstream, int startline, int startcolumn)
{ this(dstream, startline, startcolumn, 4096);
}
/** * Method to adjust line and column numbers for the start of a token.
*/ publicvoid adjustBeginLineColumn(int newLine, int newCol)
{ int start = tokenBegin; int len;
if (bufpos >= tokenBegin)
{
len = bufpos - tokenBegin + inBuf + 1;
} else
{
len = bufsize - tokenBegin + bufpos + 1 + inBuf;
}
int i = 0, j = 0, k = 0; int nextColDiff = 0, columnDiff = 0;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung ist noch experimentell.