WPXStreamImplementation.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2 /* libwpd
3  * Copyright (C) 2006 Ariya Hidayat (ariya@kde.org)
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public
16  * License along with this library; if not, write to the
17  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18  * Boston, MA 02111-1301 USA
19  *
20  * For further information visit http://libwpd.sourceforge.net
21  */
22 
23 #ifndef __WPXSTREAMIMPLEMENTATION_H__
24 #define __WPXSTREAMIMPLEMENTATION_H__
25 
26 #include "WPXStream.h"
27 
29 
31 {
32 public:
33  explicit WPXFileStream(const char *filename);
35 
36  const unsigned char *read(unsigned long numBytes, unsigned long &numBytesRead);
37  long tell();
38  int seek(long offset, WPX_SEEK_TYPE seekType);
39  bool atEOS();
40 
41  bool isOLEStream();
42  WPXInputStream *getDocumentOLEStream(const char *name);
43 
44 private:
46  WPXFileStream(const WPXFileStream &); // copy is not allowed
47  WPXFileStream &operator=(const WPXFileStream &); // assignment is not allowed
48 };
49 
51 
53 {
54 public:
55  WPXStringStream(const unsigned char *data, const unsigned int dataSize);
57 
58  const unsigned char *read(unsigned long numBytes, unsigned long &numBytesRead);
59  long tell();
60  int seek(long offset, WPX_SEEK_TYPE seekType);
61  bool atEOS();
62 
63  bool isOLEStream();
64  WPXInputStream *getDocumentOLEStream(const char *name);
65 
66 private:
68  WPXStringStream(const WPXStringStream &); // copy is not allowed
69  WPXStringStream &operator=(const WPXStringStream &); // assignment is not allowed
70 };
71 
72 #endif // __WPXSTREAMIMPLEMENTATION_H__
73 /* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */

Generated for libwpd by doxygen 1.8.3