DCL 3.7.4
Loading...
Searching...
No Matches
XFileWriter.h
Go to the documentation of this file.
1#ifndef __DCL_XFILE_WRITER_H__
2#define __DCL_XFILE_WRITER_H__ 20110218
3
4#ifndef __DCL_FILE_WRITER_H__
5#include <dcl/FileWriter.h>
6#endif
7#ifndef __DCL_THREAD_H__
8#include <dcl/Thread.h>
9#endif
10
11__DCL_BEGIN_NAMESPACE
12
22class DCLCAPI XFileWriter : public FileWriter
23{
24 DECLARE_CLASSINFO(XFileWriter)
25public:
26
27 XFileWriter(
28 const String& _path, bool _truncate,
29 CharsetEncoder* _pEncoder = NULL
31
32 XFileWriter(
33 File& __noclose__ _file,
34 CharsetEncoder* _pEncoder = NULL
36
37 XFileWriter(
38 File::HandleType __noclose__ _handle,
39 CharsetEncoder* _pEncoder = NULL
41
42 virtual void close()
44
45 virtual void flush()
47
48 virtual Writer& write(const wchar_t* _buf, size_t _n)
50
51 virtual int vprintf(const wchar_t* _format, va_list _arglist)
53
54protected:
56};
57
58inline XFileWriter::XFileWriter(
59 const String& _path, bool _truncate,
60 CharsetEncoder* _pEncoder
61 ) __DCL_THROWS1(IOException*) : FileWriter(_path, _truncate, _pEncoder)
62{
63}
64
65inline XFileWriter::XFileWriter(
66 File& __noclose__ _file,
67 CharsetEncoder* _pEncoder
68 ) __DCL_THROWS1(IOException*) : FileWriter(_file, _pEncoder)
69{
70}
71
72inline XFileWriter::XFileWriter(
73 File::HandleType __noclose__ _handle,
74 CharsetEncoder* _pEncoder
75 ) __DCL_THROWS1(IOException*) : FileWriter(_handle, _pEncoder)
76{
77}
78
79__DCL_END_NAMESPACE
80
81#endif // __DCL_XFILE_WRITER_H__
#define NULL
Definition Config.h:312
#define DCLCAPI
Definition Config.h:95
#define __noclose__
Definition Config.h:331
#define __DCL_THROWS1(e)
Definition Config.h:152
#define DECLARE_CLASSINFO(class_name)
Definition Object.h:227
Definition File.h:42
virtual void close() __DCL_THROWS1(IOException *)
virtual Writer & write(const wchar_t *_buf, size_t _n) __DCL_THROWS1(IOException *)
virtual void flush() __DCL_THROWS1(IOException *)
Thread::Mutex __lock
Definition XFileWriter.h:55