org.dbmaintain.script.parser.parsingstate
Interface ParsingState
- All Known Implementing Classes:
- BaseNormalParsingState, EscapingParsingState, InBlockCommentParsingState, InCurlyBraceBlockCommentParsingState, InDoubleQuotesParsingState, InLineCommentParsingState, InSingleQuotesParsingState, PlSqlBlockNormalParsingState, SqlStatementNormalParsingState
public interface ParsingState
A state of a parser that can handle a character and knows when the state ends and is transfered to another state.
For example, an in-block-comment state knows when the block-comment ends and then transfers control to the initial state.
- Author:
- Tim Ducheyne, Filip Neven
getNextParsingState
HandleNextCharacterResult getNextParsingState(Character previousChar,
Character currentChar,
Character nextChar,
StatementBuilder statementBuilder)
- Calculates the next parsing state from the given characters and the statement being built
- Parameters:
previousChar
- the previous char, null if nonecurrentChar
- the current charnextChar
- the next char, null if nonestatementBuilder
- The statement builder, not null
- Returns:
- the next parsing state, null if the end of the statement is reached
Copyright © 2011. All Rights Reserved.