libsesstype  2.0.0
Library for Session Types programming.
All Classes Namespaces Files Functions
Public Types | Public Member Functions
sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType > Class Template Reference

Interruptible blocks. More...

#include <interruptible.h>

Inheritance diagram for sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >:
Inheritance graph
[legend]
Collaboration diagram for sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >:
Collaboration graph
[legend]

List of all members.

Public Types

typedef
std::unordered_multimap
< RoleType *, MessageType * > 
InterruptType

Public Member Functions

 InterruptibleNodeTmpl ()
 InterruptibleNode constructor with no scope name as default.
 InterruptibleNodeTmpl (std::string scope)
 InterruptibleNode constructor.
 InterruptibleNodeTmpl (const InterruptibleNodeTmpl &node)
 InterruptibleNode copy constructor.
 ~InterruptibleNodeTmpl () override
 InterruptibleNode destructor.
InterruptibleNodeTmplclone () const override
 clone a InterruptibleNode.
void set_scope (std::string scope)
std::string scope () const
void add_interrupt (RoleType *role, MessageType *msg)
 add an interrupt specification for a Role.
unsigned int num_interrupts () const
unsigned int num_interrupts (RoleType *role) const
MessageType * interrupt_msg (RoleType *role, unsigned int index) const
InterruptType::const_iterator interrupt_begin () const
InterruptType::const_iterator interrupt_end () const
void add_throw (RoleType *role, MessageType *msg)
 add an interrupt throw for a Role.
unsigned int num_throws () const
unsigned int num_throws (RoleType *role) const
MessageType * throw_msg (RoleType *role, unsigned int index) const
InterruptType::const_iterator throw_begin () const
InterruptType::const_iterator throw_end () const
void add_catch (RoleType *role, MessageType *msg)
 add an interrupt catch for a Role.
unsigned int num_catches () const
unsigned int num_catches (RoleType *role) const
MessageType * catch_msg (RoleType *role, unsigned int index) const
InterruptType::const_iterator catch_begin () const
InterruptType::const_iterator catch_end () const
void accept (VisitorType &v) override

Detailed Description

template<class BaseNode, class RoleType, class MessageType, class VisitorType>
class sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >

Interruptible blocks.


Member Function Documentation

template<class BaseNode, class RoleType, class MessageType, class VisitorType>
void sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::add_catch ( RoleType *  role,
MessageType *  msg 
) [inline]

add an interrupt catch for a Role.

Parameters:
[in]rolethat can send interrupt.
[in]msgas an interrupt message.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
void sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::add_interrupt ( RoleType *  role,
MessageType *  msg 
) [inline]

add an interrupt specification for a Role.

Parameters:
[in]rolethat can send interrupt.
[in]msgas an interrupt message.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
void sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::add_throw ( RoleType *  role,
MessageType *  msg 
) [inline]

add an interrupt throw for a Role.

Parameters:
[in]rolethat can send interrupt.
[in]msgas an interrupt message.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
MessageType* sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::catch_msg ( RoleType *  role,
unsigned int  index 
) const [inline]
Parameters:
[in]rolethat can send interrupt.
[in]indexof the interrupt messages.
Returns:
interrupt message.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
MessageType* sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::interrupt_msg ( RoleType *  role,
unsigned int  index 
) const [inline]
Parameters:
[in]rolethat can send interrupt.
[in]indexof the interrupt messages.
Returns:
interrupt message.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_catches ( ) const [inline]
Returns:
total number of catch rules.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_catches ( RoleType *  role) const [inline]
Returns:
number of catch rules for given role.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_interrupts ( ) const [inline]
Returns:
total number of interruptible rules.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_interrupts ( RoleType *  role) const [inline]
Returns:
number of interruptible rules for given role.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_throws ( ) const [inline]
Returns:
total number of throw rules.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
unsigned int sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::num_throws ( RoleType *  role) const [inline]
Returns:
number of throw rules for given role.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
std::string sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::scope ( ) const [inline]
Returns:
scope name of interrupt.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
void sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::set_scope ( std::string  scope) [inline]
Parameters:
[in]scope_nameto set for this interrupt.
template<class BaseNode, class RoleType, class MessageType, class VisitorType>
MessageType* sesstype::InterruptibleNodeTmpl< BaseNode, RoleType, MessageType, VisitorType >::throw_msg ( RoleType *  role,
unsigned int  index 
) const [inline]
Parameters:
[in]rolethat can send interrupt.
[in]indexof the interrupt messages.
Returns:
interrupt message.

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions