Om
Public Member Functions | Static Public Member Functions | List of all members
Om::Language::Operator Class Reference

The Operator implementation. More...

#include "operator.hpp"

+ Inheritance diagram for Om::Language::Operator:
+ Collaboration diagram for Om::Language::Operator:

Public Member Functions

 Operator ()
 
 Operator (std::string const &)
 Normalizes the string and copies directly into the Operator. More...
 
 Operator (char const theCodeUnitIterator[])
 
 Operator (Om::Source::Source< CodePoint const > &)
 
 Operator (Symbol::OperandSymbol const)
 
 Operator (Symbol::OperatorSymbol const)
 
 Operator (Symbol::SeparatorSymbol const)
 
Operatoroperator= (Operator)
 
void BackGiveCodePoint (Consumer &)
 Gives the last CodePoint as an Atom. More...
 
template<boost::locale::boundary::boundary_type theSegment>
void BackGiveSegment (Consumer &)
 Gives the last segment of the given type to the Consumer. More...
 
template<typename TheConsumer >
void Decode (TheConsumer &) const
 Decodes this Operator and gives each resulting Element to the argument. More...
 
template<typename TheProducer >
void Encode (TheProducer &)
 Encodes the elements and replaces the contents of this Operator with the result. More...
 
void FrontGiveCodePoint (Consumer &)
 Gives the first CodePoint as an Atom. More...
 
template<boost::locale::boundary::boundary_type theSegment>
void FrontGiveSegment (Consumer &)
 Gives the first segment of the given type to the Consumer. More...
 
void Normalize ()
 Applies Unicode compatibility normalization. More...
 
virtual void ParseElements (Reader &)
 
virtual void ParseQuotedElements (Reader &)
 
template<typename TheOperand >
void TakeOperand (TheOperand &)
 
template<typename TheOperator >
void TakeOperator (TheOperator &)
 
template<typename TheProducer >
void TakeQuotedProducer (TheProducer &)
 
template<typename TheSeparator >
void TakeSeparator (TheSeparator &)
 
- Public Member Functions inherited from Om::Language::DefaultAtom< Operator >
virtual ~DefaultAtom ()=0
 
bool operator< (DefaultAtom const &)
 Compares with a Atom; required for use as index in containers. More...
 
virtual void Clear ()
 
bool Equals (DefaultAtom const &) const
 
bool Equals (Operator const &) const
 
virtual std::auto_ptr< Om::Source::Source< Element > > GetElementRange ()
 
virtual std::auto_ptr< Om::Source::Source< Element const > > GetElementRange () const
 
std::string const & GetString () const
 
virtual bool IsEmpty () const
 
virtual bool Merge (Operator &)
 
virtual bool Merge (Operator const &)
 
void Swap (Operator &)
 
- Public Member Functions inherited from Om::Language::DefaultElement< Operator, Om::Language::Atom >
virtual ~DefaultElement ()=0
 
virtual bool Equals (Element const &) const
 
bool Equals (Operator const &) const
 
virtual void GiveElements (Consumer &)
 
virtual void GiveElements (Consumer &) const
 
- Public Member Functions inherited from Om::Language::DefaultProgram< Operator, Om::Language::Atom >
virtual ~DefaultProgram ()=0
 
virtual bool Equals (Program const &) const
 
virtual void TakeElements (Producer &)
 
virtual void TakeElements (Producer const &)
 
- Public Member Functions inherited from Om::Language::DefaultConsumer< Operator, DefaultGiveable< Operator, Om::Language::Atom > >
virtual ~DefaultConsumer ()=0
 
virtual void TakeElement (Operand &)
 
virtual void TakeElement (Operand const &)
 
virtual void TakeElement (Operator &)
 
virtual void TakeElement (Operator const &)
 
virtual void TakeElement (Separator &)
 
virtual void TakeElement (Separator const &)
 
virtual void TakeQuotedElements (Producer &)
 
virtual void TakeQuotedElements (Producer const &)
 
- Public Member Functions inherited from Om::DefaultGiveable< Operator, Om::Language::Atom >
virtual ~DefaultGiveable ()=0
 
- Public Member Functions inherited from Om::DefaultMoveable< Operator, DefaultCopyable< Operator, Om::Language::Atom > >
virtual std::auto_ptr< MoveableMove ()
 
virtual ~DefaultMoveable ()=0
 
- Public Member Functions inherited from Om::DefaultCopyable< Operator, Om::Language::Atom >
virtual std::auto_ptr< CopyableCopy () const
 
virtual ~DefaultCopyable ()=0
 
- Public Member Functions inherited from Om::Language::Atom
virtual Programoperator * ()
 
virtual Program const & operator * () const
 
- Public Member Functions inherited from Om::Language::Element
virtual ~Element ()=0
 
Programoperator -> ()
 
Program const * operator -> () const
 
virtual bool Merge (Separator &)
 
virtual bool Merge (Separator const &)
 
virtual bool Equals (Program const &) const=0
 
virtual std::auto_ptr< Om::Source::Source< Element const > > GetElementRange () const=0
 
- Public Member Functions inherited from Om::Language::Program
virtual ~Program ()=0
 
virtual std::auto_ptr< ProgramGiveProgram ()
 Returns a new Program populated with the contents of this. More...
 
virtual std::auto_ptr< ProgramGiveProgram () const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
- Public Member Functions inherited from Om::Language::Consumer
virtual ~Consumer ()=0
 
template<typename TheOperator , typename TheSeparator >
void Parse (Reader &)
 
void TakeElement (Null &)
 Takes a Null Element, which is disregarded. More...
 
void TakeElement (Null const &)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
- Public Member Functions inherited from Om::Giveable
virtual ~Giveable ()=0
 
- Public Member Functions inherited from Om::Copyable
virtual ~Copyable ()=0
 
- Public Member Functions inherited from Om::Moveable
virtual ~Moveable ()=0
 
- Public Member Functions inherited from Om::Language::Producer
virtual ~Producer ()=0
 
- Public Member Functions inherited from Om::Shareable<>
virtual ~Shareable ()=0
 
size_t GetOwnerCount () const
 
- Public Member Functions inherited from Om::Taker< Operator >
virtual ~Taker ()=0
 
void Take (Operator &)
 Swaps. More...
 
void Take (Operator const &)
 Assigns. More...
 

Static Public Member Functions

static char const * GetName ()
 

Additional Inherited Members

- Protected Member Functions inherited from Om::Language::DefaultAtom< Operator >
 DefaultAtom ()
 
 DefaultAtom (char const theCodeUnitIterator[])
 
 DefaultAtom (char const theCodeUnit)
 
- Protected Member Functions inherited from Om::Shareable<>
 Shareable ()
 
 Shareable (Shareable const &)
 
Shareableoperator= (Shareable const &)
 
- Protected Attributes inherited from Om::Language::DefaultAtom< Operator >
std::string thisString
 The NFD-normalized string that defines the Atom. More...
 

Detailed Description

An Atom defined by any UTF-8 string.

As a Consumer, the Operator appends each taken Element verbatim.

Definition at line 59 of file operator.hpp.

Constructor & Destructor Documentation

◆ Operator() [1/7]

Om::Language::Operator::Operator ( )

◆ Operator() [2/7]

Om::Language::Operator::Operator ( std::string const &  )
explicit

◆ Operator() [3/7]

Om::Language::Operator::Operator ( char const  theCodeUnitIterator[])
explicit
Parameters
theCodeUnitIteratorA non-null pointer to the null-terminated code unit array to normalize and copy directly into the Operator.

◆ Operator() [4/7]

Om::Language::Operator::Operator ( Om::Source::Source< CodePoint const > &  )
explicit

◆ Operator() [5/7]

Om::Language::Operator::Operator ( Symbol::OperandSymbol const  )
explicit

◆ Operator() [6/7]

Om::Language::Operator::Operator ( Symbol::OperatorSymbol const  )
explicit

◆ Operator() [7/7]

Om::Language::Operator::Operator ( Symbol::SeparatorSymbol const  )
explicit

Member Function Documentation

◆ GetName()

static char const* Om::Language::Operator::GetName ( )
static

◆ operator=()

Operator& Om::Language::Operator::operator= ( Operator  )

◆ BackGiveCodePoint()

void Om::Language::Operator::BackGiveCodePoint ( Consumer )

◆ BackGiveSegment()

template<boost::locale::boundary::boundary_type theSegment>
void Om::Language::Operator::BackGiveSegment ( Consumer )

◆ Decode()

template<typename TheConsumer >
void Om::Language::Operator::Decode ( TheConsumer &  ) const

◆ Encode()

template<typename TheProducer >
void Om::Language::Operator::Encode ( TheProducer &  )

◆ FrontGiveCodePoint()

void Om::Language::Operator::FrontGiveCodePoint ( Consumer )

◆ FrontGiveSegment()

template<boost::locale::boundary::boundary_type theSegment>
void Om::Language::Operator::FrontGiveSegment ( Consumer )

◆ Normalize()

void Om::Language::Operator::Normalize ( )

◆ ParseElements()

virtual void Om::Language::Operator::ParseElements ( Reader )
virtual

◆ ParseQuotedElements()

virtual void Om::Language::Operator::ParseQuotedElements ( Reader )
virtual

◆ TakeOperand()

template<typename TheOperand >
void Om::Language::Operator::TakeOperand ( TheOperand &  )

◆ TakeOperator()

template<typename TheOperator >
void Om::Language::Operator::TakeOperator ( TheOperator &  )

◆ TakeQuotedProducer()

template<typename TheProducer >
void Om::Language::Operator::TakeQuotedProducer ( TheProducer &  )

◆ TakeSeparator()

template<typename TheSeparator >
void Om::Language::Operator::TakeSeparator ( TheSeparator &  )

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