LPEX
3.6.6

com.ibm.lpex.fortran
Interface IFortranLexer

All Known Implementing Classes:
FixedFormLexer, FreeFormLexer

public interface IFortranLexer

Interface FortranLexer can be implemented to define a Fortran lexer to be used by a FortranParser.


Method Summary
 void initialize()
          Initializes the Fortran lexer.
 int processToken()
          Retrieves and processes the next Fortran token.
 void reinitialize()
          Reinitializes the Fortran lexer.
 void setTaskTags(String[] taskTags)
          Sets the comment tags for tasks (TODOs) to be used by the lexer.
 

Method Detail

initialize

void initialize()
Initializes the Fortran lexer. The token manager is initialized for the same character input stream, and in the default lexical state (DEFAULT). This method is normally called when the host parser sets or switches the active lexer to this lexer.


reinitialize

void reinitialize()
Reinitializes the Fortran lexer. The token manager is reinitialized for the same character input stream, and in the default lexical state (DEFAULT). This method is normally called after a TokenMgrError exception (e.g., encountered EOF in the middle of a token / a bad character), after the token in error is skipped and parsing is continued.


processToken

int processToken()
Retrieves and processes the next Fortran token.

Returns:
LEXER_RC_OK, LEXER_RC_EOF [+LEXER_RC_MORE]
See Also:
LpexCommonParser.LEXER_RC_OK, LpexCommonParser.LEXER_RC_EOF, LpexCommonParser.LEXER_RC_MORE

setTaskTags

void setTaskTags(String[] taskTags)
Sets the comment tags for tasks (TODOs) to be used by the lexer.

Parameters:
taskTags - array of non-null, non-empty strings, or null if no task tags in effect

LPEX
3.6.6

Copyright © 2012 IBM Corp. All Rights Reserved.

Note: This documentation is for part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.