AIML Class Reference

AIML class that represents the AIML XML tag "aiml". More...

#include <AIML.h>

Inheritance diagram for AIML:

Tag List of all members.

Public Member Functions

 AIML (GraphBuilderFramework &builder) throw (InternalProgrammerErrorException &)
 Initalizes the private implementation (m_pimpl) data and sets the private implementation with a reference to the GraphBuilderFramework.
virtual void handleInnerTag (const shared_ptr< Tag > &tag) throw (InternalProgrammerErrorException &)
 Calls its internal default Topic Object's Topic::handleInnerTag() with this AIML XML tag.
virtual void setAttribute (const StringPimpl &name, const StringPimpl &value) throw (InternalProgrammerErrorException &)
 Sets its attribute of "version".
virtual ~AIML ()
 Default virtual destructor.

Private Attributes

shared_ptr< AIMLImpl > m_pimpl
 The private implementation in which you cannot get access to.

Detailed Description

AIML class that represents the AIML XML tag "aiml".

Every time a XML Tag of AIML is encountered, an instance of this class will be created. All text inbetween the begin and end tag, all attributes, and all inner Tags will go through methods of this class.


Constructor & Destructor Documentation

AIML GraphBuilderFramework builder  )  throw (InternalProgrammerErrorException &)
 

Initalizes the private implementation (m_pimpl) data and sets the private implementation with a reference to the GraphBuilderFramework.

Also creates a default Topic object which is important for AIML::handleInnerTag

Parameters:
builder A reference to the graph builder framework that can be used to set and get information from the AIML engine.
Exceptions:
InternalProgrammerErrorException is thrown only if the error is so grave that the entire AIML engine has to be shut down.

virtual ~AIML  )  [virtual]
 

Default virtual destructor.

Destroys the private implementation (m_pimpl) data.


Member Function Documentation

virtual void handleInnerTag const shared_ptr< Tag > &  tag  )  throw (InternalProgrammerErrorException &) [virtual]
 

Calls its internal default Topic Object's Topic::handleInnerTag() with this AIML XML tag.

Whenever the AIML Tag encounters an inner AIML XML Tag it's always either a Category Tag or a Topic Tag. If it is a Category Tag it sends the Tag to its internal default Topic Tag object by calling its internal Topic Tag's handleInnerTag. If it is a Topic Tag it safetly ignores it. The default Topic Tag is a Topic Tag with its topic set to "*". When a Topic is not specified in AIML XML, it is to default to "*". When a Topic is not specified, this handleInnerTag gets called with a Category Tag object which in turn calls the internal default Topic Tag with the Category Tag object. When a Topic is specified AIML's handleInnerTag gets called with a Topic Object and safetly ignores it since it does not need to do anything with it.

Parameters:
tag The Category Tag or Topic Tag
Exceptions:
InternalProgrammerErrorException is thrown only if the error is so grave that the entire AIML engine has to be shut down.

Reimplemented from Tag.

virtual void setAttribute const StringPimpl name,
const StringPimpl value
throw (InternalProgrammerErrorException &) [virtual]
 

Sets its attribute of "version".

Parameters:
name The name of the AIML XML attribute
value The value of the AIML XML attribute
Exceptions:
InternalProgrammerErrorException is thrown only if the error is so grave that the entire AIML engine has to be shut down.

Reimplemented from Tag.


Member Data Documentation

shared_ptr<AIMLImpl> m_pimpl [private]
 

The private implementation in which you cannot get access to.

This shared_ptr holds the private methods and private member variables of this class. This makes ABI (Application Binary Interface) more resilient to change. See the private implementation idiom on the internet for more information about this.

Reimplemented from Tag.


The documentation for this class was generated from the following file:
Generated on Thu Sep 7 22:05:52 2006 for RebeccaAIML by  doxygen 1.4.5