MSPUBMetaData.h Source File documentation

MSPUBMetaData.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /*
3 * This file is part of the libmspub project.
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
10 #ifndef INCLUDED_MSPUBMETADATA_H
11 #define INCLUDED_MSPUBMETADATA_H
12
13 #include <map>
14 #include <utility>
15 #include <vector>
16
17 #include <librevenge/librevenge.h>
18
19 #include <librevenge-stream/librevenge-stream.h>
20
21 namespace libmspub
22 {
23
24 class MSPUBMetaData
25 {
26 public:
27 MSPUBMetaData();
28 ~MSPUBMetaData();
29 bool parse(librevenge::RVNGInputStream *input);
30 bool parseTimes(librevenge::RVNGInputStream *input);
31 const librevenge::RVNGPropertyList &getMetaData();
32
33 private:
34 MSPUBMetaData(const MSPUBMetaData &);
35 MSPUBMetaData &operator=(const MSPUBMetaData &);
36
37 void readPropertySetStream(librevenge::RVNGInputStream *input);
38 void readPropertySet(librevenge::RVNGInputStream *input, uint32_t offset, char *FMTID);
39 void readPropertyIdentifierAndOffset(librevenge::RVNGInputStream *input);
40 void readTypedPropertyValue(librevenge::RVNGInputStream *input, uint32_t index, uint32_t offset, char *FMTID);
41 librevenge::RVNGString readCodePageString(librevenge::RVNGInputStream *input);
42
43 uint32_t getCodePage();
44
45 std::vector< std::pair<uint32_t, uint32_t> > m_idsAndOffsets;
46 std::map<uint16_t, uint16_t> m_typedPropertyValues;
47 librevenge::RVNGPropertyList m_metaData;
48 };
49
50 } // namespace libmspub
51
52 #endif // INCLUDED_MSPUBMETADATA_H
53
54 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libmspub::MSPUBMetaData::readPropertyIdentifierAndOffset
void readPropertyIdentifierAndOffset(librevenge::RVNGInputStream *input)
Definition: MSPUBMetaData.cpp:156
libmspub::readU32
uint32_t readU32(librevenge::RVNGInputStream *input)
Definition: libmspub_utils.cpp:292
libmspub::readU64
uint64_t readU64(librevenge::RVNGInputStream *input)
Definition: libmspub_utils.cpp:316
libmspub::MSPUBMetaData::parseTimes
bool parseTimes(librevenge::RVNGInputStream *input)
Definition: MSPUBMetaData.cpp:276
PIDSI_APPNAME
Definition: MSPUBMetaData.cpp:79
PIDDSI_DIGSIG
Definition: MSPUBMetaData.cpp:53
MSPUB_DEBUG_MSG
#define MSPUB_DEBUG_MSG(M)
Definition: libmspub_utils.h:55
libmspub::readU8
uint8_t readU8(librevenge::RVNGInputStream *input)
Definition: libmspub_utils.cpp:266
PIDSI_LASTAUTHOR
Definition: MSPUBMetaData.cpp:69
PIDDSI_PRESFORMAT
Definition: MSPUBMetaData.cpp:33
libmspub
Definition: Arrow.h:13
MSPUBMetaData.h
PIDSI_EDITTIME
Definition: MSPUBMetaData.cpp:71
VT_LPSTR
#define VT_LPSTR
Definition: MSPUBMetaData.cpp:164
libmspub::MSPUBMetaData::m_idsAndOffsets
std::vector< std::pair< uint32_t, uint32_t > > m_idsAndOffsets
Definition: MSPUBMetaData.h:45
libmspub::readU16
uint16_t readU16(librevenge::RVNGInputStream *input)
Definition: libmspub_utils.cpp:285
PIDDSI_HLINKS
Definition: MSPUBMetaData.cpp:50
libmspub_utils.h
PIDSI_REVNUMBER
Definition: MSPUBMetaData.cpp:70
libmspub::MSPUBMetaData::parse
bool parse(librevenge::RVNGInputStream *input)
Definition: MSPUBMetaData.cpp:83
libmspub::MSPUBMetaData::~MSPUBMetaData
~MSPUBMetaData()
Definition: MSPUBMetaData.cpp:25
PIDSI_AUTHOR
Definition: MSPUBMetaData.cpp:65
PIDDSI_HEADINGPAIR
Definition: MSPUBMetaData.cpp:42
PIDDSI_CATEGORY
Definition: MSPUBMetaData.cpp:32
PIDDSI_HIDDENCOUNT
Definition: MSPUBMetaData.cpp:39
PIDDSI_DOCPARTS
Definition: MSPUBMetaData.cpp:43
PIDDSI_SLIDECOUNT
Definition: MSPUBMetaData.cpp:37
PIDSI_PAGECOUNT
Definition: MSPUBMetaData.cpp:75
PIDSI_COMMENTS
Definition: MSPUBMetaData.cpp:67
PIDDSI_PARACOUNT
Definition: MSPUBMetaData.cpp:36
PIDDSI_LANGUAGE
Definition: MSPUBMetaData.cpp:56
libmspub::MSPUBMetaData::MSPUBMetaData
MSPUBMetaData()
Definition: MSPUBMetaData.cpp:20
PIDDSI_DOCVERSION
Definition: MSPUBMetaData.cpp:57
PIDDSI_CCHWITHSPACES
Definition: MSPUBMetaData.cpp:47
PIDSI_CREATE_DTM
Definition: MSPUBMetaData.cpp:73
VT_I2
#define VT_I2
Definition: MSPUBMetaData.cpp:163
PIDDSI_SCALE
Definition: MSPUBMetaData.cpp:41
PIDSI_TITLE
Definition: MSPUBMetaData.cpp:63
PIDDSI_VERSION
Definition: MSPUBMetaData.cpp:52
PIDDSI_SHAREDDOC
Definition: MSPUBMetaData.cpp:48
PIDDSI_BYTECOUNT
Definition: MSPUBMetaData.cpp:34
PIDSI_LASTSAVE_DTM
Definition: MSPUBMetaData.cpp:74
PIDSI_DOC_SECURITY
Definition: MSPUBMetaData.cpp:80
libmspub::MSPUBMetaData::m_typedPropertyValues
std::map< uint16_t, uint16_t > m_typedPropertyValues
Definition: MSPUBMetaData.h:46
PIDDSI_CODEPAGE
Definition: MSPUBMetaData.cpp:31
PIDSI_KEYWORDS
Definition: MSPUBMetaData.cpp:66
PIDDSI_COMPANY
Definition: MSPUBMetaData.cpp:45
PIDDSI_LINECOUNT
Definition: MSPUBMetaData.cpp:35
PIDDSI_MMCLIPCOUNT
Definition: MSPUBMetaData.cpp:40
PIDSI_WORDCOUNT
Definition: MSPUBMetaData.cpp:76
PIDSI_LASTPRINTED
Definition: MSPUBMetaData.cpp:72
libmspub::MSPUBMetaData::readTypedPropertyValue
void readTypedPropertyValue(librevenge::RVNGInputStream *input, uint32_t index, uint32_t offset, char *FMTID)
Definition: MSPUBMetaData.cpp:166
libmspub::MSPUBMetaData
Definition: MSPUBMetaData.h:24
libmspub::MSPUBMetaData::m_metaData
librevenge::RVNGPropertyList m_metaData
Definition: MSPUBMetaData.h:47
CODEPAGE_PROPERTY_IDENTIFIER
Definition: MSPUBMetaData.cpp:62
libmspub::MSPUBMetaData::getMetaData
const librevenge::RVNGPropertyList & getMetaData()
Definition: MSPUBMetaData.cpp:328
PIDDSI_NOTECOUNT
Definition: MSPUBMetaData.cpp:38
PIDSI_CHARCOUNT
Definition: MSPUBMetaData.cpp:77
libmspub::MSPUBMetaData::readPropertySet
void readPropertySet(librevenge::RVNGInputStream *input, uint32_t offset, char *FMTID)
Definition: MSPUBMetaData.cpp:124
libmspub::MSPUBMetaData::getCodePage
uint32_t getCodePage()
Definition: MSPUBMetaData.cpp:141
libmspub::MSPUBMetaData::readPropertySetStream
void readPropertySetStream(librevenge::RVNGInputStream *input)
Definition: MSPUBMetaData.cpp:93
PIDSI
PIDSI
Definition: MSPUBMetaData.cpp:60
PIDDSI_CONTENTSTATUS
Definition: MSPUBMetaData.cpp:55
PIDDSI_HYPERLINKSCHANGED
Definition: MSPUBMetaData.cpp:51
PIDDSI_CONTENTTYPE
Definition: MSPUBMetaData.cpp:54
PIDSI_THUMBNAIL
Definition: MSPUBMetaData.cpp:78
PIDDSI_MANAGER
Definition: MSPUBMetaData.cpp:44
PIDSI_SUBJECT
Definition: MSPUBMetaData.cpp:64
libmspub::MSPUBMetaData::operator=
MSPUBMetaData & operator=(const MSPUBMetaData &)
PIDDSI_LINKBASE
Definition: MSPUBMetaData.cpp:49
PIDDSI
PIDDSI
Definition: MSPUBMetaData.cpp:29
libmspub::MSPUBMetaData::readCodePageString
librevenge::RVNGString readCodePageString(librevenge::RVNGInputStream *input)
Definition: MSPUBMetaData.cpp:239
PIDSI_TEMPLATE
Definition: MSPUBMetaData.cpp:68
libmspub::appendCharacters
void appendCharacters(librevenge::RVNGString &text, const std::vector< unsigned char > &characters, const char *encoding)
Definition: libmspub_utils.cpp:383
PIDDSI_LINKSDIRTY
Definition: MSPUBMetaData.cpp:46