org.apache.lucene.demo.html

Class SimpleCharStream

public class SimpleCharStream extends Object

An implementation of interface CharStream, where the stream is assumed to contain only ASCII characters (without unicode processing).
Field Summary
protected int[]bufcolumn
protected char[]buffer
protected int[]bufline
intbufpos
protected intcolumn
protected intinBuf
protected ReaderinputStream
protected intline
protected intmaxNextCharInd
protected booleanprevCharIsCR
protected booleanprevCharIsLF
static booleanstaticFlag
Constructor Summary
SimpleCharStream(Reader dstream, int startline, int startcolumn, int buffersize)
SimpleCharStream(Reader dstream, int startline, int startcolumn)
SimpleCharStream(Reader dstream)
SimpleCharStream(InputStream dstream, int startline, int startcolumn, int buffersize)
SimpleCharStream(InputStream dstream, int startline, int startcolumn)
SimpleCharStream(InputStream dstream)
Method Summary
voidadjustBeginLineColumn(int newLine, int newCol)
Method to adjust line and column numbers for the start of a token.
voidbackup(int amount)
charBeginToken()
voidDone()
protected voidExpandBuff(boolean wrapAround)
protected voidFillBuff()
intgetBeginColumn()
intgetBeginLine()
intgetColumn()
intgetEndColumn()
intgetEndLine()
intgetLine()
StringGetImage()
char[]GetSuffix(int len)
charreadChar()
voidReInit(Reader dstream, int startline, int startcolumn, int buffersize)
voidReInit(Reader dstream, int startline, int startcolumn)
voidReInit(Reader dstream)
voidReInit(InputStream dstream, int startline, int startcolumn, int buffersize)
voidReInit(InputStream dstream)
voidReInit(InputStream dstream, int startline, int startcolumn)
protected voidUpdateLineColumn(char c)

Field Detail

bufcolumn

protected int[] bufcolumn

buffer

protected char[] buffer

bufline

protected int[] bufline

bufpos

public int bufpos

column

protected int column

inBuf

protected int inBuf

inputStream

protected Reader inputStream

line

protected int line

maxNextCharInd

protected int maxNextCharInd

prevCharIsCR

protected boolean prevCharIsCR

prevCharIsLF

protected boolean prevCharIsLF

staticFlag

public static final boolean staticFlag

Constructor Detail

SimpleCharStream

public SimpleCharStream(Reader dstream, int startline, int startcolumn, int buffersize)

SimpleCharStream

public SimpleCharStream(Reader dstream, int startline, int startcolumn)

SimpleCharStream

public SimpleCharStream(Reader dstream)

SimpleCharStream

public SimpleCharStream(InputStream dstream, int startline, int startcolumn, int buffersize)

SimpleCharStream

public SimpleCharStream(InputStream dstream, int startline, int startcolumn)

SimpleCharStream

public SimpleCharStream(InputStream dstream)

Method Detail

adjustBeginLineColumn

public void adjustBeginLineColumn(int newLine, int newCol)
Method to adjust line and column numbers for the start of a token.

backup

public void backup(int amount)

BeginToken

public char BeginToken()

Done

public void Done()

ExpandBuff

protected void ExpandBuff(boolean wrapAround)

FillBuff

protected void FillBuff()

getBeginColumn

public int getBeginColumn()

getBeginLine

public int getBeginLine()

getColumn

public int getColumn()

Deprecated:

See Also: SimpleCharStream

getEndColumn

public int getEndColumn()

getEndLine

public int getEndLine()

getLine

public int getLine()

Deprecated:

See Also: SimpleCharStream

GetImage

public String GetImage()

GetSuffix

public char[] GetSuffix(int len)

readChar

public char readChar()

ReInit

public void ReInit(Reader dstream, int startline, int startcolumn, int buffersize)

ReInit

public void ReInit(Reader dstream, int startline, int startcolumn)

ReInit

public void ReInit(Reader dstream)

ReInit

public void ReInit(InputStream dstream, int startline, int startcolumn, int buffersize)

ReInit

public void ReInit(InputStream dstream)

ReInit

public void ReInit(InputStream dstream, int startline, int startcolumn)

UpdateLineColumn

protected void UpdateLineColumn(char c)
Copyright © 2000-2008 Apache Software Foundation. All Rights Reserved.