#include <system.hh>
Public Member Functions | |
bool | can_be_modified () const |
Tells, whether current system can be modified. | |
bool | can_decompose_property () const |
Tells, whether current system is able to work with processes. | |
bool | can_processes () const |
Tells, whether current system is able to work with processes. | |
bool | can_property_process () const |
Tells, whether current system is able to work with property process. | |
bool | can_transitions () const |
Tells, whether current system is able to work with transitions. | |
const system_abilities_t & | get_abilities () const |
Returns a structure storing a list of abilities of current system. | |
system_abilities_t & | get_abilities () |
Returns a structure storing a list of abilities of current system. | |
const error_vector_t & | get_error_vector () const |
Returns a constant reference to the error_vector_t inside of system_t. | |
error_vector_t & | get_error_vector () |
Returns a reference to the error_vector_t inside of system_t. | |
bool | get_with_property () const |
Returns, whether a property process is specified or not. | |
void | set_with_property (const bool is_with) |
Sets, wheter system is the system with a property process. | |
system_t (error_vector_t &evect=gerr) | |
A constructor. | |
virtual | ~system_t () |
A destructor. | |
Methods modifying a system | |
virtual void | add_process (process_t *const process)=0 |
Method for adding of process to system. | |
virtual void | remove_process (const size_int_t process_id)=0 |
Method for removing of process from system. | |
Obligatory part of abstact interface | |
virtual slong_int_t | from_string (const std::string str)=0 |
Method for reading a model of a system from a source stored in a string. | |
virtual property_type_t | get_property_type ()=0 |
virtual slong_int_t | read (const char *const filename)=0 |
Method for reading a model of a system from a file. | |
virtual slong_int_t | read (std::istream &ins=std::cin)=0 |
Method for reading a model of a system from a stream. | |
virtual std::string | to_string ()=0 |
virtual void | write (std::ostream &outs=std::cout)=0 |
virtual bool | write (const char *const filename)=0 |
Method for writing currently stored model of a system to a file. | |
Methods working with processes | |
virtual const process_t * | get_process (const size_int_t gid) const =0 |
Returns a constant instance of a process with process GID `gid'. | |
virtual process_t * | get_process (const size_int_t gid)=0 |
Returns a process with process GID `gid'. | |
virtual size_int_t | get_process_count () const =0 |
Returns a count of processes in the system. | |
Methods to check the SCCs of property process graph | |
virtual process_decomposition_t * | get_property_decomposition () |
Returns property decomposition, or 0, if subsystem is not available. | |
Methods working with property process | |
virtual size_int_t | get_property_gid () const =0 |
Returns GID of property process. | |
virtual const process_t * | get_property_process () const =0 |
Returns a pointer to the constant instance of property process. | |
virtual process_t * | get_property_process ()=0 |
Returns a pointer to the property process. | |
virtual void | set_property_gid (const size_int_t gid)=0 |
Sets, which process is a property process. | |
Methods working with transitions | |
virtual size_int_t | get_trans_count () const =0 |
Returns the count of all transitions in the system. | |
virtual const transition_t * | get_transition (size_int_t gid) const =0 |
Returns a constant instance of transition with transition GID = `gid'. | |
virtual transition_t * | get_transition (size_int_t gid)=0 |
Returns a transition with transition GID = `gid'. | |
Static Public Attributes | |
static const ERR_id_t | ERR_FILE_NOT_OPEN = 65134 |
static const ERR_type_t | ERR_TYPE_SYSTEM = 100 |
Protected Member Functions | |
void | copy_private_part (const system_t &second) |
Protected Attributes | |
system_abilities_t | abilities |
error_vector_t & | terr |
bool | with_property |
This class provides an interface to the model of system. Depending on abilities (see get_abilities()) you can more or less deeply analyse the model.
Furthermore you can generate states of the system using child class explitcit_system_t (and its children)
system_t | ( | error_vector_t & | evect = gerr |
) | [inline] |
A constructor.
evect | = the error vector, that will be used by created instance of system_t |
virtual void add_process | ( | process_t *const | process | ) | [pure virtual] |
Method for adding of process to system.
This method is implemented only if can_be_modified() returns true.
Implemented in bymoc_system_t, and dve_system_t.
bool can_be_modified | ( | ) | const [inline] |
Tells, whether current system can be modified.
Generally thr system can be modified using add_process() and remove_process() together with methods modifying processes
virtual slong_int_t from_string | ( | const std::string | str | ) | [pure virtual] |
Method for reading a model of a system from a source stored in a string.
str | = string to read |
Implemented in bymoc_system_t, and dve_system_t.
const system_abilities_t& get_abilities | ( | ) | const [inline] |
Returns a structure storing a list of abilities of current system.
It also stores the list of abilites of processes and transitions, which are a part of a system and abilities of explicit system
system_abilities_t& get_abilities | ( | ) | [inline] |
Returns a structure storing a list of abilities of current system.
It also stores the list of abilites of processes and transitions, which are a part of a system and abilities of explicit system
Referenced by bymoc_explicit_system_t::bymoc_explicit_system_t(), transition_t::can_be_modified(), process_t::can_be_modified(), transition_t::can_read(), process_t::can_read(), process_t::can_transitions(), dve_explicit_system_t::dve_explicit_system_t(), and dve_system_t::dve_system_t().
virtual const process_t* get_process | ( | const size_int_t | gid | ) | const [pure virtual] |
Returns a constant instance of a process with process GID `gid'.
gid | = process GID of a process (can be any from an interval 0..(get_process_count()-1) ) |
Implemented in bymoc_system_t, and dve_system_t.
virtual process_t* get_process | ( | const size_int_t | gid | ) | [pure virtual] |
Returns a process with process GID `gid'.
gid | = process GID of a process (can be any from an interval 0..(get_process_count()-1) ) |
Implemented in bymoc_system_t, and dve_system_t.
Referenced by prob_system_t::consolidate().
virtual size_int_t get_process_count | ( | ) | const [pure virtual] |
Returns a count of processes in the system.
This method is implemented only if can_processes_true_methods() returns true.
Implemented in bymoc_system_t, and dve_system_t.
Referenced by prob_system_t::consolidate(), and enabled_trans_container_t::enabled_trans_container_t().
virtual size_int_t get_property_gid | ( | ) | const [pure virtual] |
Returns GID of property process.
This method is implemented only if can_property_process() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual const process_t* get_property_process | ( | ) | const [pure virtual] |
Returns a pointer to the constant instance of property process.
This method is implemented only if can_property_process() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual process_t* get_property_process | ( | ) | [pure virtual] |
Returns a pointer to the property process.
This method is implemented only if can_property_process() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual property_type_t get_property_type | ( | ) | [pure virtual] |
Method for identifying type of the accepting condition of the property process. Possible types are NONE, BUCHI, GENBUCHI, MULLER, RABIN, STREETT.
Implemented in bymoc_explicit_system_t, bymoc_system_t, and dve_system_t.
virtual size_int_t get_trans_count | ( | ) | const [pure virtual] |
Returns the count of all transitions in the system.
This method is implemented only if can_transitions() returns true.
Implemented in bymoc_system_t, and dve_system_t.
Referenced by prob_system_t::consolidate().
virtual const transition_t* get_transition | ( | size_int_t | gid | ) | const [pure virtual] |
Returns a constant instance of transition with transition GID = `gid'.
This method is implemented only if can_transitions() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual transition_t* get_transition | ( | size_int_t | gid | ) | [pure virtual] |
Returns a transition with transition GID = `gid'.
This method is implemented only if can_transitions() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual slong_int_t read | ( | const char *const | filename | ) | [pure virtual] |
Method for reading a model of a system from a file.
filename | = path to a source of a model |
Implemented in bymoc_system_t, dve_explicit_system_t, dve_prob_explicit_system_t, and dve_system_t.
virtual slong_int_t read | ( | std::istream & | ins = std::cin |
) | [pure virtual] |
Method for reading a model of a system from a stream.
ins | = input stream containing a source of a model |
Implemented in bymoc_system_t, dve_prob_explicit_system_t, and dve_system_t.
virtual void remove_process | ( | const size_int_t | process_id | ) | [pure virtual] |
Method for removing of process from system.
This method is implemented only if can_be_modified() returns true.
Implemented in bymoc_system_t, and dve_system_t.
virtual void set_property_gid | ( | const size_int_t | gid | ) | [pure virtual] |
Sets, which process is a property process.
gid | = GID of new property process |
Implemented in bymoc_system_t, and dve_system_t.
virtual std::string to_string | ( | ) | [pure virtual] |
Method for writing source of actually stored model of a system to the string
Implemented in bymoc_system_t, and dve_system_t.
virtual void write | ( | std::ostream & | outs = std::cout |
) | [pure virtual] |
Method for writing currently stored model of a system to a stream. (parameter `outs')
Implemented in bymoc_system_t, and dve_system_t.
virtual bool write | ( | const char *const | filename | ) | [pure virtual] |
Method for writing currently stored model of a system to a file.
filename | = path to a file |
Implemented in bymoc_system_t, and dve_system_t.