Design Patterns
tcp_closed.h
Go to the documentation of this file.
1 // Based on "Design Patterns: Elements of Reusable Object-Oriented Software"
2 // book by Erich Gamma, John Vlissides, Ralph Johnson, and Richard Helm
3 //
4 // Created by Bartosz Rachwal. The National Institute of Advanced Industrial Science and Technology, Japan.
5 
6 #ifndef OPERATIONAL_STATE_EVENT_H_
7 #define OPERATIONAL_STATE_EVENT_H_
8 
9 #include "tcp_state.h"
10 
11 namespace operational
12 {
13 namespace state
14 {
15 class TcpClosed : public TcpState
16 {
17  public:
18  TcpClosed();
19 
20  void Initialize(TcpState* established, TcpState* listen);
21 
22  virtual void ActiveOpen(TcpConnection*) override;
23  virtual void PassiveOpen(TcpConnection*) override;
24 
25  std::string Info() const override;
26 
27  private:
28  TcpState* established_;
29  TcpState* listen_;
30 };
31 }
32 }
33 
34 #endif
35 
virtual void PassiveOpen(TcpConnection *) override
Definition: tcp_closed.cc:26
Definition: application.cc:10
std::string Info() const override
Definition: tcp_closed.cc:31
void Initialize(TcpState *established, TcpState *listen)
Definition: tcp_closed.cc:14
Definition: tcp_state.h:15
TcpClosed()
Definition: tcp_closed.cc:12
Definition: tcp_closed.h:15
virtual void ActiveOpen(TcpConnection *) override
Definition: tcp_closed.cc:20
Definition: tcp_connection.h:17