Design Patterns
ascii7_stream.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 STRUCTURAL_DECORATOR_ASCII7_STREAM_H_
7 #define STRUCTURAL_DECORATOR_ASCII7_STREAM_H_
8 
9 #include "stream_decorator.h"
10 
11 namespace structural
12 {
13 namespace decorator
14 {
16 {
17  public:
18  explicit ASCII7Stream(StreamInterface*);
19 
20  void PutInt(int) override;
21  void PutString(const std::string&) override;
22  int value() const;
23  std::string &message();
24 
25  private:
26  int value_;
27  std::string text_string_;
28 };
29 }
30 }
31 
32 #endif
33 
Definition: shape_interface.h:11
std::string & message()
Definition: ascii7_stream.cc:36
void PutInt(int) override
Definition: ascii7_stream.cc:16
void PutString(const std::string &) override
Definition: ascii7_stream.cc:22
ASCII7Stream(StreamInterface *)
Definition: ascii7_stream.cc:14
int value() const
Definition: ascii7_stream.cc:31
Definition: ascii7_stream.h:15
Definition: stream_decorator.h:15
Definition: stream_interface.h:15