132
|
1 /*******************************************************************************
|
|
2
|
|
3 copyright: Copyright (c) 2007 Kris Bell. All rights reserved
|
|
4
|
|
5 license: BSD style: $(LICENSE)
|
|
6
|
|
7 version: Initial release: Oct 2007
|
|
8
|
|
9 author: Kris
|
|
10
|
|
11 *******************************************************************************/
|
|
12
|
|
13 module tango.io.stream.FileStream;
|
|
14
|
|
15 public import tango.io.FileConduit;
|
|
16
|
|
17 /*******************************************************************************
|
|
18
|
|
19 Trivial wrapper around a FileConduit
|
|
20
|
|
21 *******************************************************************************/
|
|
22
|
|
23 class FileInput : FileConduit
|
|
24 {
|
|
25 /***********************************************************************
|
|
26
|
|
27 Open a file for reading. Don't forget to use close()
|
|
28
|
|
29 ***********************************************************************/
|
|
30
|
|
31 this (char[] path, FileConduit.Style style = FileConduit.ReadExisting)
|
|
32 {
|
|
33 super (path, style);
|
|
34 }
|
|
35 }
|
|
36
|
|
37
|
|
38 /*******************************************************************************
|
|
39
|
|
40 Trivial wrapper around a FileConduit
|
|
41
|
|
42 *******************************************************************************/
|
|
43
|
|
44 class FileOutput : FileConduit
|
|
45 {
|
|
46 /***********************************************************************
|
|
47
|
|
48 Open a file for writing. Don't forget to use close()
|
|
49
|
|
50 ***********************************************************************/
|
|
51
|
|
52 this (char[] path, FileConduit.Style style = FileConduit.WriteCreate)
|
|
53 {
|
|
54 super (path, style);
|
|
55 }
|
|
56 }
|
|
57
|