SimulationCraft
SimulationCraft is a tool to explore combat mechanics in the popular MMO RPG World of Warcraft (tm).
AutoUTFOutputStream< CharType, OutputByteStream > Class Template Reference

Output stream wrapper with dynamically bound encoding and automatic encoding detection. More...

#include <encodedstream.h>

Public Types

typedef CharType Ch
 

Public Member Functions

 AutoUTFOutputStream (OutputByteStream &os, UTFType type, bool putBOM)
 Constructor. More...
 
UTFType GetType () const
 
void Put (Ch c)
 
void Flush ()
 
Ch Peek () const
 
Ch Take ()
 
size_t Tell () const
 
Ch * PutBegin ()
 
size_t PutEnd (Ch *)
 

Detailed Description

template<typename CharType, typename OutputByteStream>
class AutoUTFOutputStream< CharType, OutputByteStream >

Output stream wrapper with dynamically bound encoding and automatic encoding detection.

Template Parameters
CharTypeType of character for writing.
OutputByteStreamtype of output byte stream to be wrapped.

Constructor & Destructor Documentation

◆ AutoUTFOutputStream()

template<typename CharType , typename OutputByteStream >
AutoUTFOutputStream< CharType, OutputByteStream >::AutoUTFOutputStream ( OutputByteStream &  os,
UTFType  type,
bool  putBOM 
)
inline

Constructor.

Parameters
osoutput stream to be wrapped.
typeUTF encoding type.
putBOMWhether to write BOM at the beginning of the stream.