Nebula
Loading...
Searching...
No Matches
textwriter.h
Go to the documentation of this file.
1#pragma once
2#ifndef IO_TEXTWRITER_H
3#define IO_TEXTWRITER_H
4//------------------------------------------------------------------------------
14#include "io/streamwriter.h"
15
16//------------------------------------------------------------------------------
17namespace IO
18{
20{
22public:
24 TextWriter();
26 virtual ~TextWriter();
28 void WriteChar(unsigned char c);
30 void WriteString(const Util::String& str);
32 void WriteFormatted(const char* fmtString, ...);
34 void WriteLine(const Util::String& line);
36 void WriteLines(const Util::Array<Util::String>& lines);
38 template<typename T> void Write(const T& t);
39};
40
41} // namespace IO
42//------------------------------------------------------------------------------
43#endif
Stream writer classes provide a specialized write-interface for a stream.
Definition streamwriter.h:22
A friendly interface for writing text data to a stream.
Definition textwriter.h:20
void WriteLines(const Util::Array< Util::String > &lines)
write a number of lines, separated by new-lines
Definition textwriter.cc:80
void WriteChar(unsigned char c)
write a single character
Definition textwriter.cc:38
TextWriter()
constructor
Definition textwriter.cc:18
__DeclareClass(TextWriter)
void WriteString(const Util::String &str)
write a string
Definition textwriter.cc:47
virtual ~TextWriter()
destructor
Definition textwriter.cc:26
void WriteFormatted(const char *fmtString,...)
write some formatted text
Definition textwriter.cc:56
void Write(const T &t)
generic writer method
void WriteLine(const Util::String &line)
write a line of text and append a new-line
Definition textwriter.cc:70
A line in 3d space.
Definition line.h:22
Nebula's dynamic array class.
Definition array.h:60
Instances of wrapped stream classes.
Definition orientation.cc:10
Nebula's universal string class.
Definition string.h:50