DCL
4.0
Loading...
Searching...
No Matches
XFileOutputStream.h
Go to the documentation of this file.
1
#ifndef __DCL_XFILE_OUTPUT_STREAM_H__
2
#define __DCL_XFILE_OUTPUT_STREAM_H__ 20110218
3
4
#ifndef __DCL_FILE_OUTPUT_STREAM_H__
5
#include <
dcl/FileOutputStream.h
>
6
#endif
7
#ifndef __DCL_THREAD_H__
8
#include <
dcl/Thread.h
>
9
#endif
10
11
__DCL_BEGIN_NAMESPACE
12
22
class
DCLCAPI
XFileOutputStream :
public
FileOutputStream
23
{
24
DECLARE_CLASSINFO
(XFileOutputStream)
25
public
:
26
27
XFileOutputStream(
const
String& _path,
bool
_truncate =
true
)
28
__DCL_THROWS1
(
IOException
*);
29
30
XFileOutputStream(
File
&
__noclose__
_file)
31
__DCL_THROWS1
(
IOException
*);
32
33
XFileOutputStream(File::HandleType
__noclose__
_handle)
34
__DCL_THROWS1
(
IOException
*);
35
36
virtual
void
close()
37
__DCL_THROWS1
(
IOException
*);
38
39
virtual
void
flush()
40
__DCL_THROWS1
(
IOException
*);
41
42
virtual
OutputStream
& write(
const
void
* _buf,
size_t
_n)
43
__DCL_THROWS1
(
IOException
*);
44
45
virtual
int
vprintf(
const
char
* _format, va_list _arglist)
46
__DCL_THROWS1
(
IOException
*);
47
48
protected
:
49
Thread::Mutex
__lock
;
50
};
51
52
inline
XFileOutputStream::XFileOutputStream(
const
String& _path,
bool
_truncate)
53
__DCL_THROWS1
(
IOException
*)
54
:
FileOutputStream
(_path, _truncate)
55
{
56
}
57
58
inline
XFileOutputStream::XFileOutputStream(
File
&
__noclose__
_file)
59
__DCL_THROWS1
(
IOException
*)
60
:
FileOutputStream
(_file)
61
{
62
}
63
64
inline
XFileOutputStream::XFileOutputStream(File::HandleType
__noclose__
_handle)
65
__DCL_THROWS1
(
IOException
*)
66
:
FileOutputStream
(_handle)
67
{
68
}
69
70
__DCL_END_NAMESPACE
71
72
#endif
// __DCL_XFILE_OUTPUT_STREAM_H__
DCLCAPI
#define DCLCAPI
Definition
Config.h:100
__noclose__
#define __noclose__
Definition
Config.h:360
__DCL_THROWS1
#define __DCL_THROWS1(e)
Definition
Config.h:167
FileOutputStream.h
DECLARE_CLASSINFO
#define DECLARE_CLASSINFO(class_name)
Definition
Object.h:210
Thread.h
File
Definition
File.h:38
FileOutputStream
Definition
FileOutputStream.h:24
IOException
Definition
Exception.h:93
OutputStream
Definition
OutputStream.h:31
Thread::Mutex
Definition
Thread.h:264
XFileOutputStream::__lock
Thread::Mutex __lock
Definition
XFileOutputStream.h:49
include
dcl
XFileOutputStream.h
Generated by
1.14.0