Outstation handle.
More...
#include <dnp3.hpp>
|
static Outstation | create_serial_session (Runtime &runtime, const std::string &serial_path, const SerialSettings &settings, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler) |
| Create an outstation instance running on a serial port. More...
|
|
static Outstation | create_serial_session_fault_tolerant (Runtime &runtime, const std::string &serial_path, const SerialSettings &settings, std::chrono::steady_clock::duration open_retry_delay, const OutstationConfig &config, std::unique_ptr< OutstationApplication > application, std::unique_ptr< OutstationInformation > information, std::unique_ptr< ControlHandler > control_handler) |
| Create an outstation instance running on a serial port which is tolerant to the serial port being added and removed. More...
|
|
|
class | CppOutstationFriend |
|
Outstation handle.
Use this handle to modify the internal database.
◆ Outstation()
dnp3::Outstation::Outstation |
( |
Outstation && |
other | ) |
|
|
inlinenoexcept |
Transfer ownership of the underlying C-type to this instance and invalidate the other instance.
- Note
- the moved class will now throw an exception if any method is called
- Parameters
-
other | Class from which ownership will be transfer to this instance |
◆ ~Outstation()
dnp3::Outstation::~Outstation |
( |
| ) |
|
◆ create_serial_session()
Create an outstation instance running on a serial port.
The port is opened immediately on the calling thread and fails if not successful
- Warning
- Most users should prefer the fault tolerant version of the this method Outstation::create_serial_session_fault_tolerant()
- Parameters
-
runtime | runtime on which to spawn the outstation |
serial_path | Path of the serial device |
settings | settings for the serial port |
config | outstation configuration |
application | application interface |
information | informational events interface |
control_handler | control handler interface |
- Returns
- Outstation instance or
NULL
if the port cannot be opened
- Exceptions
-
◆ create_serial_session_fault_tolerant()
Create an outstation instance running on a serial port which is tolerant to the serial port being added and removed.
- Parameters
-
runtime | runtime on which to spawn the outstation |
serial_path | Path of the serial device |
settings | settings for the serial port |
open_retry_delay | delay between attempts to open the serial port |
config | outstation configuration |
application | application interface |
information | informational events interface |
control_handler | control handler interface |
- Returns
- Outstation instance or
NULL
if the port cannot be opened
- Exceptions
-
◆ set_decode_level()
void dnp3::Outstation::set_decode_level |
( |
const DecodeLevel & |
level | ) |
|
Set decoding log level.
- Parameters
-
- Exceptions
-
◆ transaction()
Acquire a mutex on the underlying database and apply a set of changes as a transaction.
- Parameters
-
callback | Interface on which to execute the transaction |
The documentation for this class was generated from the following file: