class VarMap

A VarMap contains all information for legal protocol variables. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods


Detailed Description

It contains all the possible protocols. All the possible variables those protocols support and whether the variables are read-only or read-write.

This is crutial for semantic checking.

VarMapErr (class)

VarMapErr

enum Access { READ, READ_WRITE }

Access

A variable may be READ [readonly] or READ_WRITE [read/write].

Variable (struct)

Variable

A variable has Access control, it has a name, and a type.

typedef map<string,Variable*> VariableMap

VariableMap

typedef map<string,VariableMap*> ProtoMap

ProtoMap

const Variable&  variable (const string& protocol, const string& varname)

variable

[const]

Return Variable information for a variable of a specific protocol.

Throws an exception if no information is found.

Caller must not delete the map.

Parameters:

protocolprotocol of variable interested in.
varnamename of variable interested in.

Returns: access and type information for the requested variable.

 VarMap (ProcessWatchBase& pw)

VarMap

As the VarMap learns about new protocols, it will register interest with the process watcher for that protocol to monitor the status of the protocol process.

Parameters:

pwprocessWatch to use.
 ~VarMap ()

~VarMap

bool  protocol_known (const string& protocol)

protocol_known

Parameters:

protocolprotocol caller wish to knows existance of.

Returns: True if the protocol is known to the VarMap, false otherwise.

void  add_variable (VariableMap& vm, const string& varname, const string& type, Access acc)

add_variable

Add a variable to a specific protocol.

Parameters:

vmVariableMap where variable should be added.
varnamename of the variable.
typethe type [id] of the variable/element.
accthe access of the variable.
void  add_protocol_variable (const string& protocol, const string& varname, const string& type, Access acc)

add_protocol_variable

Add a variable to a protocol.

Parameters:

protocolprotocol for which variable should be added.
varnamename of variable.
typetype [id] of the variable.
accaccess [r/rw] of the variable.
void  configure (const string& conf)

configure

Configure the VarMap from an unparsed configuration.

Parameters:

confun-parsed configuration file of the VarMap.

Generated by: pavlin on possum.icir.org on Wed Apr 13 21:53:13 2005, using kdoc $.