MultiAgentDecisionProcess
Policy Class Referenceabstract

Policy is a class that represents a policy for a single agent. More...

#include <Policy.h>

Inheritance diagram for Policy:
[legend]

Public Member Functions

virtual PolicyClone () const =0
 Returns a pointer to a copy of this class. More...
 
size_t GetDepth () const
 Returns the depth of the policy. More...
 
 Policy (Index agentI)
 Constructor, initializes the depth to the maximum horizon. More...
 
virtual void Print () const
 Prints a description of a policy to cout. More...
 
virtual void SetDepth (size_t d)
 Sets the depth of the policy. More...
 
virtual std::string SoftPrint () const =0
 Prints a description of a policy to a string. More...
 
virtual ~Policy ()
 Destructor. More...
 

Protected Attributes

Index _m_agentI
 

Private Attributes

size_t _m_depth
 The depth of this joint policy. More...
 

Detailed Description

Policy is a class that represents a policy for a single agent.

It contains the notion of the depth of a policy: a positive number that specifies for how many time steps this policy is specified. I.e., if depth < horizon, the object represents a partially specified policy (specified for time steps 0,...,depth-1)

Constructor & Destructor Documentation

Policy::Policy ( Index  agentI)
inline

Constructor, initializes the depth to the maximum horizon.

virtual Policy::~Policy ( )
inlinevirtual

Destructor.

Member Function Documentation

virtual Policy* Policy::Clone ( ) const
pure virtual

Returns a pointer to a copy of this class.

Implemented in PolicyDiscrete, PolicyPureVector, and PolicyDiscretePure.

size_t Policy::GetDepth ( ) const
inline

Returns the depth of the policy.

See also
_m_depth

References _m_depth.

Referenced by PolicyPureVector::GetIndex(), PolicyPureVector::Increment(), and PolicyPureVector::SetIndex().

virtual void Policy::Print ( ) const
inlinevirtual

Prints a description of a policy to cout.

References SoftPrint().

virtual void Policy::SetDepth ( size_t  d)
inlinevirtual

Sets the depth of the policy.

See also
_m_depth

Reimplemented in PolicyPureVector.

Referenced by PolicyPureVector::SetDepth().

virtual std::string Policy::SoftPrint ( ) const
pure virtual

Prints a description of a policy to a string.

Implemented in PolicyPureVector.

Referenced by Print().

Member Data Documentation

Index Policy::_m_agentI
protected
size_t Policy::_m_depth
private

The depth of this joint policy.

The depth of the policy is the number of stages for which it specifies actions. It ranges from:
0 (the empty policy),
1 (a policy specified only for ts=0),
: MAXHORIZON (a policy specified for all stages, the default value).

Referenced by GetDepth().