- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

RVNGBinaryData.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- */
2 /* librevenge
3 * Version: MPL 2.0 / LGPLv2.1+
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * Major Contributor(s):
10 * Copyright (C) 2007 Fridrich Strba (fridrich.strba@bluewin.ch)
11 *
12 * For minor contributions see the git repository.
13 *
14 * Alternatively, the contents of this file may be used under the terms
15 * of the GNU Lesser General Public License Version 2.1 or later
16 * (LGPLv2.1+), in which case the provisions of the LGPLv2.1+ are
17 * applicable instead of those above.
18 */
19
20 #ifndef RVNGBINARYDATA_H
21 #define RVNGBINARYDATA_H
22
23 #include <librevenge-stream/librevenge-stream.h>
24 #include "RVNGString.h"
25
26 namespace librevenge
27 {
28
29 struct RVNGBinaryDataImpl;
30
31 class RVNGBinaryData
32 {
33 public:
34 RVNGBinaryData();
35 RVNGBinaryData(const RVNGBinaryData &);
36 RVNGBinaryData(const unsigned char *buffer, const unsigned long bufferSize);
37 explicit RVNGBinaryData(const RVNGString &base64);
38 explicit RVNGBinaryData(const char *base64);
39 ~RVNGBinaryData();
40
41 void append(const RVNGBinaryData &data);
42 void append(const unsigned char *buffer, const unsigned long bufferSize);
43 void append(const unsigned char c);
44 void appendBase64Data(const RVNGString &base64);
45 void appendBase64Data(const char *base64);
46 void clear();
47
48 unsigned long size() const;
49 bool empty() const;
50 const unsigned char *getDataBuffer() const;
51 const RVNGString getBase64Data() const;
52 const RVNGInputStream *getDataStream() const;
53
54 RVNGBinaryData &operator=(const RVNGBinaryData &);
55
56 private:
57 RVNGBinaryDataImpl *m_binaryDataImpl;
58 };
59
60 }
61
62 #endif
63 /* vim:set shiftwidth=4 softtabstop=4 noexpandtab: */
librevenge::RVNGBinaryData::~RVNGBinaryData
~RVNGBinaryData()
Definition: RVNGBinaryData.cpp:103
librevenge::RVNGBinaryData::append
void append(const RVNGBinaryData &data)
Definition: RVNGBinaryData.cpp:149
librevenge::RVNGBinaryData::appendBase64Data
void appendBase64Data(const RVNGString &base64)
Definition: RVNGBinaryData.cpp:159
librevenge::RVNGBinaryData::RVNGBinaryData
RVNGBinaryData()
Definition: RVNGBinaryData.cpp:108
RVNGString.h
librevenge::RVNGBinaryData::getBase64Data
const RVNGString getBase64Data() const
Definition: RVNGBinaryData.cpp:231
librevenge::RVNGBinaryData::clear
void clear()
Definition: RVNGBinaryData.cpp:202
librevenge::RVNGBinaryData::empty
bool empty() const
Definition: RVNGBinaryData.cpp:213
librevenge::RVNGBinaryData
Definition: RVNGBinaryData.h:31
librevenge::RVNGBinaryData::getDataBuffer
const unsigned char * getDataBuffer() const
Definition: RVNGBinaryData.cpp:224
librevenge::RVNGBinaryData::size
unsigned long size() const
Definition: RVNGBinaryData.cpp:209
librevenge::RVNGBinaryData::getDataStream
const RVNGInputStream * getDataStream() const
Definition: RVNGBinaryData.cpp:238
librevenge::RVNGBinaryDataImpl
Definition: RVNGBinaryData.cpp:79
librevenge::RVNGInputStream
Definition: RVNGStream.h:33
librevenge::RVNGBinaryData::m_binaryDataImpl
RVNGBinaryDataImpl * m_binaryDataImpl
Definition: RVNGBinaryData.h:57
librevenge::RVNGString
Definition: RVNGString.h:29
librevenge-stream.h
librevenge::RVNGBinaryData::operator=
RVNGBinaryData & operator=(const RVNGBinaryData &)
Definition: RVNGBinaryData.cpp:218