OFFIS DCMTK  Version 3.6.0
dcistrmb.h
1 /*
2  *
3  * Copyright (C) 1994-2010, OFFIS e.V.
4  * All rights reserved. See COPYRIGHT file for details.
5  *
6  * This software and supporting documentation were developed by
7  *
8  * OFFIS e.V.
9  * R&D Division Health
10  * Escherweg 2
11  * D-26121 Oldenburg, Germany
12  *
13  *
14  * Module: dcmdata
15  *
16  * Author: Marco Eichelberg
17  *
18  * Purpose: DcmInputBufferStream and related classes,
19  * implements input to blocks of memory as needed in the dcmnet module.
20  *
21  * Last Update: $Author: joergr $
22  * Update Date: $Date: 2010-10-14 13:15:41 $
23  * CVS/RCS Revision: $Revision: 1.6 $
24  * Status: $State: Exp $
25  *
26  * CVS/RCS Log at end of file
27  *
28  */
29 
30 #ifndef DCISTRMB_H
31 #define DCISTRMB_H
32 
33 #include "dcmtk/config/osconfig.h"
34 #include "dcmtk/dcmdata/dcistrma.h"
35 
36 
41 {
42 public:
46 
48  virtual ~DcmBufferProducer();
49 
54  virtual OFBool good() const;
55 
60  virtual OFCondition status() const;
61 
65  virtual OFBool eos();
66 
74  virtual offile_off_t avail();
75 
81  virtual offile_off_t read(void *buf, offile_off_t buflen);
82 
87  virtual offile_off_t skip(offile_off_t skiplen);
88 
93  virtual void putback(offile_off_t num);
94 
100  virtual void setBuffer(const void *buf, offile_off_t buflen);
101 
108  virtual void releaseBuffer();
109 
113  virtual void setEos();
114 
115 private:
116 
119 
122 
124  unsigned char *buffer_;
125 
127  unsigned char *backup_;
128 
130  offile_off_t bufSize_;
131 
133  offile_off_t bufIndex_;
134 
136  offile_off_t backupIndex_;
137 
139  offile_off_t backupStart_;
140 
143 
145  OFBool eosflag_;
146 
147 };
148 
149 
154 {
155 public:
159 
161  virtual ~DcmInputBufferStream();
162 
172  virtual DcmInputStreamFactory *newFactory() const;
173 
179  virtual void setBuffer(const void *buf, offile_off_t buflen);
180 
187  virtual void releaseBuffer();
188 
192  virtual void setEos();
193 
194 private:
195 
198 
201 
204 
205 };
206 
207 
208 #endif
209 
210 /*
211  * CVS/RCS Log:
212  * $Log: dcistrmb.h,v $
213  * Revision 1.6 2010-10-14 13:15:41 joergr
214  * Updated copyright header. Added reference to COPYRIGHT file.
215  *
216  * Revision 1.5 2008-06-23 12:09:13 joergr
217  * Fixed inconsistencies in Doxygen API documentation.
218  *
219  * Revision 1.4 2007/02/19 15:45:41 meichel
220  * Class DcmInputStream and related classes are now safe for use with
221  * large files (2 GBytes or more) if supported by compiler and operating system.
222  *
223  * Revision 1.3 2005/12/08 16:28:16 meichel
224  * Changed include path schema for all DCMTK header files
225  *
226  * Revision 1.2 2003/06/12 13:34:36 joergr
227  * Fixed inconsistent API documentation reported by Doxygen.
228  *
229  * Revision 1.1 2002/08/27 16:55:33 meichel
230  * Initial release of new DICOM I/O stream classes that add support for stream
231  * compression (deflated little endian explicit VR transfer syntax)
232  *
233  *
234  */


Generated on Thu Dec 20 2012 for OFFIS DCMTK Version 3.6.0 by Doxygen 1.8.2