class PolicyList

The list of policies associated with a protocol. More...

 
LOGO
 Annotated List  Files  Globals  Hierarchy  Index  Top

Public Types

Public Methods


Detailed Description

This relates to the import/export directives of protocols.

Depending on what protocols support, they will normally have a single import/export policy list associated with them.

Each policy list is an instantiation of a policy, and thus it hold the specific code for this instantiation.

typedef set<uint32_t> TagSet

TagSet

typedef map<string,TagSet*> TagMap

TagMap

enum PolicyType { IMPORT, EXPORT }

PolicyType

 PolicyList (const string& p, PolicyType pt, PolicyMap& pmap, SetMap& smap, VarMap& vmap)

PolicyList

Parameters:

pprotocol for which this list applies.
ptthe type of policy list [import/export].
pmapthe container of all policies.
smapthe container of all sets.
vmapthe VarMap.
 ~PolicyList ()

~PolicyList

void  push_back (const string& policyname)

push_back

Append a policy to the list.

Parameters:

policynamethe name of the policy
void  compile_policy (PolicyStatement& ps, Code::TargetSet& mod, uint32_t& tagstart)

compile_policy

Compiles a specific policy.

Throws an exception on semantic / compile errors.

Parameters:

pspolicy to compile.
modset filled with targets which are modified by compilation.
tagstartfirst policy tag available.
void  compile (Code::TargetSet& mod, uint32_t& tagstart)

compile

Compile all policies which were not previously compiled.

Throws an exception on semantic / compile errors.

Parameters:

modset filled with targets which are modified by compilation.
tagstartfirst policy tag available.
string  str ()

str

Returns: string representation of list

void  link_code (Code& ret)

link_code

Link the all the code avialable in this policy list with code supplied.

The code supplied will normally contain a target, so only relevant code is linked.

Parameters:

retcode to link with.
void  get_targets (Code::TargetSet& targets)

get_targets

Return all targets in this policy list.

Parameters:

targetsset filled with all targets in this policy instantiation.
void  get_tags (const string& protocol, Code::TagSet& ts)

get_tags

Return all policy tags for a specific protocol.

Parameters:

protocolprotocol for which tags are requesdted.
tsset filled with policy-tags used by the protocol.

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