Canola  0.8.D001
Public Types | Public Member Functions | Protected Member Functions | Private Member Functions
lexer_functor Class Reference

#include <functor.h>

Inheritance diagram for lexer_functor:
lexer_functor_method lexer_functor_method_bool lexer_functor_opcode lexer_functor_program_mode

List of all members.

Public Types

typedef boost::shared_ptr
< lexer_functor
pointer

Public Member Functions

virtual ~lexer_functor ()
void operator() (const location::pointer &where)
lexer_functoroperator= (const lexer_functor &rhs)

Protected Member Functions

virtual void do_it (const location::pointer &where)=0
 lexer_functor ()

Private Member Functions

 lexer_functor (const lexer_functor &rhs)

Detailed Description

The lexer_functor class is used to represent an arbitrary action to be performed when a keyword is seen by the lexer.

Definition at line 29 of file functor.h.


Member Typedef Documentation

typedef boost::shared_ptr<lexer_functor> lexer_functor::pointer

Constructor & Destructor Documentation

The destructor.

Definition at line 21 of file functor.cc.

The default constructor. For use by derived classes only.

Definition at line 26 of file functor.cc.

lexer_functor::lexer_functor ( const lexer_functor rhs) [private]

The copy constructor. Do not use.

Parameters:
rhsThe right hand side of the initialization.

Member Function Documentation

virtual void lexer_functor::do_it ( const location::pointer where) [protected, pure virtual]

The do_it method is provided by each derived class, to actually perform the actions of the functor.

Implemented in lexer_functor_method_bool, lexer_functor_method, lexer_functor_opcode, and lexer_functor_program_mode.

void lexer_functor::operator() ( const location::pointer where) [inline]

The function call operator, with a location argument, is to make this object look like a function, that's why it's called a functor.

Definition at line 43 of file functor.h.

lexer_functor& lexer_functor::operator= ( const lexer_functor rhs)

The assignment operator. Do not use.

Parameters:
rhsThe right hand side of the assignment.

The documentation for this class was generated from the following files: