Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
sysio::chain::maybe_session Class Reference

Public Member Functions

 maybe_session ()=default
 
 maybe_session (maybe_session &&other)
 
 maybe_session (database &db)
 
 maybe_session (const maybe_session &)=delete
 
void squash ()
 
void undo ()
 
void push ()
 
maybe_sessionoperator= (maybe_session &&mv)
 

Detailed Description

Definition at line 66 of file controller.cpp.

Constructor & Destructor Documentation

◆ maybe_session() [1/4]

sysio::chain::maybe_session::maybe_session ( )
default

◆ maybe_session() [2/4]

sysio::chain::maybe_session::maybe_session ( maybe_session && other)
inline

Definition at line 70 of file controller.cpp.

71 :_session(move(other._session))
72 {
73 }

◆ maybe_session() [3/4]

sysio::chain::maybe_session::maybe_session ( database & db)
inlineexplicit

Definition at line 75 of file controller.cpp.

75 {
76 _session.emplace(db.start_undo_session(true));
77 }
Here is the call graph for this function:

◆ maybe_session() [4/4]

sysio::chain::maybe_session::maybe_session ( const maybe_session & )
delete

Member Function Documentation

◆ operator=()

maybe_session & sysio::chain::maybe_session::operator= ( maybe_session && mv)
inline

Definition at line 96 of file controller.cpp.

96 {
97 if (mv._session) {
98 _session.emplace(move(*mv._session));
99 mv._session.reset();
100 } else {
101 _session.reset();
102 }
103
104 return *this;
105 };

◆ push()

void sysio::chain::maybe_session::push ( )
inline

Definition at line 91 of file controller.cpp.

91 {
92 if (_session)
93 _session->push();
94 }
Here is the caller graph for this function:

◆ squash()

void sysio::chain::maybe_session::squash ( )
inline

Definition at line 81 of file controller.cpp.

81 {
82 if (_session)
83 _session->squash();
84 }
Here is the caller graph for this function:

◆ undo()

void sysio::chain::maybe_session::undo ( )
inline

Definition at line 86 of file controller.cpp.

86 {
87 if (_session)
88 _session->undo();
89 }

The documentation for this class was generated from the following file: