SoftBookResourceDir.h Source File documentation

SoftBookResourceDir.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 libe-book 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 SOFTBOOKRESOURCEDIR_H_INCLUDED
11 #define SOFTBOOKRESOURCEDIR_H_INCLUDED
12
13 namespace libebook
14 {
15
16 class SoftBookHeader;
17 class SoftBookResourceDirImpl;
18
21 class SoftBookResourceDir
22 {
23 public:
24 SoftBookResourceDir(librevenge::RVNGInputStream *input, const SoftBookHeader &header);
25
33 std::shared_ptr<librevenge::RVNGInputStream> getNameStream() const;
34
41 std::shared_ptr<librevenge::RVNGInputStream> getTypeStream() const;
42
43 private:
44 std::shared_ptr<SoftBookResourceDirImpl> m_impl;
45 };
46
47 }
48
49 #endif // SOFTBOOKRESOURCEDIR_H_INCLUDED
50
51 /* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libebook::SoftBookResourceDirImpl::ResourceInfo::length
unsigned length
Definition: SoftBookResourceDir.cpp:78
m_resourceDir
const shared_ptr< SoftBookResourceDirImpl > m_resourceDir
Definition: SoftBookResourceDir.cpp:52
libebook::SoftBookResourceDir::SoftBookResourceDir
SoftBookResourceDir(librevenge::RVNGInputStream *input, const SoftBookHeader &header)
Definition: SoftBookResourceDir.cpp:202
SoftBookResourceDir.h
libebook::SoftBookResourceDir::getTypeStream
std::shared_ptr< librevenge::RVNGInputStream > getTypeStream() const
Get OLE stream for this resource directory.
Definition: SoftBookResourceDir.cpp:216
libebook::SoftBookResourceDirImpl::m_length
unsigned m_length
Definition: SoftBookResourceDir.cpp:101
libebook::SoftBookResourceDirImpl::findResourceByType
ResourceMap_t::const_iterator findResourceByType(const char *type) const
Definition: SoftBookResourceDir.cpp:324
libebook::SoftBookResourceDirImpl::ResourceInfo::type
optional< string > type
Definition: SoftBookResourceDir.cpp:79
libebook::EBOOKHTMLToken::get
@ get
Definition: EBOOKHTMLToken.h:283
libebook
Definition: BBeBCollector.cpp:19
libebook::SoftBookHeader
Definition: SoftBookHeader.h:19
libebook_utils.h
libebook::EBOOKMemoryStream
Definition: EBOOKMemoryStream.h:21
libebook::SoftBookResourceDir::m_impl
std::shared_ptr< SoftBookResourceDirImpl > m_impl
Definition: SoftBookResourceDir.h:44
libebook::SoftBookResourceDirImpl::m_resourceMap
ResourceMap_t m_resourceMap
Definition: SoftBookResourceDir.cpp:102
libebook::readNBytes
const unsigned char * readNBytes(librevenge::RVNGInputStream *const input, const unsigned long numBytes)
Definition: libebook_utils.cpp:105
m_stream
const shared_ptr< librevenge::RVNGInputStream > m_stream
Definition: SoftBookResourceDir.cpp:51
EBOOKMemoryStream.h
offset
unsigned offset
Definition: SoftBookParser.cpp:74
libebook::EBOOKHTMLToken::i
@ i
Definition: EBOOKHTMLToken.h:86
libebook::SoftBookResourceDirImpl::SoftBookResourceDirImpl
SoftBookResourceDirImpl(const SoftBookResourceDirImpl &other)
libebook::SoftBookResourceDirImpl::m_start
unsigned m_start
Definition: SoftBookResourceDir.cpp:100
libebook::seek
void seek(librevenge::RVNGInputStream *const input, const unsigned long pos)
Definition: libebook_utils.cpp:152
data
MSPackFileData * data
Definition: HTMLHelpStream.cpp:63
libebook::EBOOKHTMLToken::input
@ input
Definition: EBOOKHTMLToken.h:89
libebook::readU16
uint16_t readU16(librevenge::RVNGInputStream *input, bool bigEndian)
Definition: libebook_utils.cpp:57
libebook::SoftBookResourceDirImpl
Definition: SoftBookResourceDir.cpp:68
libebook::SoftBookResourceDirImpl::operator=
SoftBookResourceDirImpl & operator=(const SoftBookResourceDirImpl &other)
libebook::SoftBookResourceDirImpl::ResourceInfo
Definition: SoftBookResourceDir.cpp:74
libebook::readU32
uint32_t readU32(librevenge::RVNGInputStream *input, bool bigEndian)
Definition: libebook_utils.cpp:73
libebook::SoftBookResourceDirImpl::m_stream
librevenge::RVNGInputStream * m_stream
Definition: SoftBookResourceDir.cpp:99
libebook::EBOOKHTMLToken::header
@ header
Definition: EBOOKHTMLToken.h:82
libebook::SoftBookResourceDirImpl::ResourceMap_t
std::unordered_map< string, ResourceInfo > ResourceMap_t
Definition: SoftBookResourceDir.cpp:82
name
string name
Definition: HTMLHelpStream.cpp:80
libebook::SoftBookResourceDirImpl::getResourceByType
librevenge::RVNGInputStream * getResourceByType(const char *type) const
Definition: SoftBookResourceDir.cpp:307
libebook::SoftBookResourceDirImpl::createStream
librevenge::RVNGInputStream * createStream(const ResourceInfo &info) const
Definition: SoftBookResourceDir.cpp:350
libebook::SoftBookResourceDir
Read the resource tree and provide access to it as an OLE stream.
Definition: SoftBookResourceDir.h:22
libebook::SoftBookResourceDirImpl::m_typeMap
TypeMap_t m_typeMap
Definition: SoftBookResourceDir.cpp:103
libebook::SoftBookResourceDirImpl::TypeMap_t
std::unordered_map< string, ResourceMap_t::const_iterator > TypeMap_t
Definition: SoftBookResourceDir.cpp:83
EBOOK_DEBUG_MSG
#define EBOOK_DEBUG_MSG(M)
Definition: libebook_utils.h:44
libebook::SoftBookResourceDir::getNameStream
std::shared_ptr< librevenge::RVNGInputStream > getNameStream() const
Get OLE stream for this resource directory.
Definition: SoftBookResourceDir.cpp:209
type
EBOOKDocument::Type type
Definition: EBOOKDocument.cpp:325
SoftBookHeader.h
libebook::SoftBookResourceDirImpl::ResourceInfo::ResourceInfo
ResourceInfo()
Definition: SoftBookResourceDir.cpp:223
libebook::SoftBookResourceDirImpl::getDirStream
librevenge::RVNGInputStream * getDirStream() const
Definition: SoftBookResourceDir.cpp:289
libebook::skip
void skip(librevenge::RVNGInputStream *input, unsigned long numBytes)
Definition: libebook_utils.cpp:145
libebook::SoftBookResourceDirImpl::getResourceByName
librevenge::RVNGInputStream * getResourceByName(const char *name) const
Definition: SoftBookResourceDir.cpp:296
libebook::EBOOKOPFToken::version
@ version
Definition: EBOOKOPFToken.h:97
libebook::SoftBookResourceDirImpl::ResourceInfo::offset
unsigned offset
Definition: SoftBookResourceDir.cpp:77
libebook::GenericException
Definition: libebook_utils.h:106
length
unsigned length
Definition: SoftBookParser.cpp:73