LibreOffice Module lotuswordpro (master) 1
Public Member Functions | Private Types | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
LwpObjectStream Class Reference

stream class for LwpObject body data provide stream like interface to read object data More...

#include <lwpobjstrm.hxx>

Collaboration diagram for LwpObjectStream:
[legend]

Public Member Functions

 LwpObjectStream (LwpSvStream *pStrm, bool isCompressed, sal_uInt16 size)
 @descr ctor() from LwpSvStream More...
 
 ~LwpObjectStream ()
 
sal_uInt16 remainingSize () const
 
sal_uInt16 QuickRead (void *buf, sal_uInt16 len)
 @descr read len bytes from object stream to buffer More...
 
sal_uInt16 GetPos () const
 
void SeekRel (sal_uInt16 pos)
 @descr SeekRel pos in object stream/buffer More...
 
void Seek (sal_uInt16 pos)
 @descr Seek to pos in object buffer/buffer More...
 
void SkipExtra ()
 @descr skip extra bytes More...
 
sal_uInt16 CheckExtra ()
 @descr check if extra bytes More...
 
bool QuickReadBool ()
 @descr Quick read sal_Bool More...
 
sal_uInt32 QuickReaduInt32 (bool *pFailure=nullptr)
 @descr Quick read sal_uInt32 More...
 
sal_uInt16 QuickReaduInt16 (bool *pFailure=nullptr)
 @descr Quick read sal_uInt32 More...
 
sal_uInt8 QuickReaduInt8 (bool *pFailure=nullptr)
 @descr Quick read sal_uInt8 More...
 
sal_Int32 QuickReadInt32 ()
 @descr Quick read sal_Int32 More...
 
sal_Int16 QuickReadInt16 ()
 @descr Quick read sal_Int16 More...
 
double QuickReadDouble ()
 @descr Quick read double More...
 
OUString QuickReadStringPtr ()
 @descr quick read string with 1252 More...
 
void ReadComplete ()
 @descr signal complete to release object buffer More...
 
LwpSvStreamGetStream ()
 

Private Types

enum  { IO_BUFFERSIZE = 0xFF00 }
 

Private Member Functions

void Read2Buffer ()
 @descr read object data from stream to buffer More...
 
sal_uInt8AllocBuffer (sal_uInt16 size)
 @descr alloc size of buffer More...
 
void ReleaseBuffer ()
 @descr release object buffer More...
 

Static Private Member Functions

static sal_uInt16 DecompressBuffer (sal_uInt8 *pDst, sal_uInt8 *pSrc, sal_uInt16 Size)
 @descr decompress data buffer from pSrc to pDst Refer to the CAmiPro40File::DecompressObject(~) in LWP More...
 

Private Attributes

sal_uInt8m_pContentBuf
 
sal_uInt8 m_SmallBuffer [100]
 
std::vector< sal_uInt8m_BigBuffer
 
sal_uInt16 m_nBufSize
 
sal_uInt16 m_nReadPos
 
LwpSvStreamm_pStrm
 
bool m_bCompressed
 

Detailed Description

stream class for LwpObject body data provide stream like interface to read object data

Definition at line 76 of file lwpobjstrm.hxx.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private
Enumerator
IO_BUFFERSIZE 

Definition at line 86 of file lwpobjstrm.hxx.

Constructor & Destructor Documentation

◆ LwpObjectStream()

LwpObjectStream::LwpObjectStream ( LwpSvStream pStrm,
bool  isCompressed,
sal_uInt16  size 
)

@descr ctor() from LwpSvStream

Definition at line 67 of file lwpobjstrm.cxx.

References IO_BUFFERSIZE, m_nBufSize, Read2Buffer(), and size.

◆ ~LwpObjectStream()

LwpObjectStream::~LwpObjectStream ( )

Definition at line 128 of file lwpobjstrm.cxx.

References ReleaseBuffer().

Member Function Documentation

◆ AllocBuffer()

sal_uInt8 * LwpObjectStream::AllocBuffer ( sal_uInt16  size)
private

@descr alloc size of buffer

Definition at line 114 of file lwpobjstrm.cxx.

References m_BigBuffer, m_SmallBuffer, and size.

Referenced by Read2Buffer().

◆ CheckExtra()

sal_uInt16 LwpObjectStream::CheckExtra ( )

◆ DecompressBuffer()

sal_uInt16 LwpObjectStream::DecompressBuffer ( sal_uInt8 pDst,
sal_uInt8 pSrc,
sal_uInt16  Size 
)
staticprivate

@descr decompress data buffer from pSrc to pDst Refer to the CAmiPro40File::DecompressObject(~) in LWP

Definition at line 272 of file lwpobjstrm.cxx.

References IO_BUFFERSIZE.

Referenced by Read2Buffer().

◆ GetPos()

sal_uInt16 LwpObjectStream::GetPos ( ) const
inline

Definition at line 98 of file lwpobjstrm.hxx.

References m_nReadPos.

Referenced by LwpTools::IsUnicodePacked().

◆ GetStream()

LwpSvStream * LwpObjectStream::GetStream ( )
inline

Definition at line 124 of file lwpobjstrm.hxx.

References m_pStrm.

Referenced by LwpIndexManager::ReadObjIndexData().

◆ QuickRead()

sal_uInt16 LwpObjectStream::QuickRead ( void *  buf,
sal_uInt16  len 
)

@descr read len bytes from object stream to buffer

Definition at line 143 of file lwpobjstrm.cxx.

References m_nBufSize, m_nReadPos, and m_pContentBuf.

Referenced by QuickReadBool(), QuickReadDouble(), QuickReadInt16(), QuickReadInt32(), QuickReaduInt16(), QuickReaduInt32(), QuickReaduInt8(), and LwpTools::QuickReadUnicode().

◆ QuickReadBool()

bool LwpObjectStream::QuickReadBool ( )

◆ QuickReadDouble()

double LwpObjectStream::QuickReadDouble ( )

@descr Quick read double

Definition at line 241 of file lwpobjstrm.cxx.

References d, i, and QuickRead().

◆ QuickReadInt16()

sal_Int16 LwpObjectStream::QuickReadInt16 ( )

@descr Quick read sal_Int16

Definition at line 220 of file lwpobjstrm.cxx.

References QuickRead().

Referenced by LwpRotor::Read().

◆ QuickReadInt32()

sal_Int32 LwpObjectStream::QuickReadInt32 ( )

◆ QuickReadStringPtr()

OUString LwpObjectStream::QuickReadStringPtr ( )

@descr quick read string with 1252

Definition at line 355 of file lwpobjstrm.cxx.

References QuickReaduInt16(), and LwpTools::QuickReadUnicode().

◆ QuickReaduInt16()

sal_uInt16 LwpObjectStream::QuickReaduInt16 ( bool *  pFailure = nullptr)

@descr Quick read sal_uInt32

Definition at line 200 of file lwpobjstrm.cxx.

References QuickRead().

Referenced by CheckExtra(), LwpFrib::CreateFrib(), LwpNumericFormatSubset::QuickRead(), LwpRowColumnQualifier::QuickRead(), LwpRowSpecifier::QuickRead(), LwpColumnSpecifier::QuickRead(), QuickReadStringPtr(), LwpTools::QuickReadUnicode(), LwpNumericFormat::Read(), LwpCellLayout::Read(), LwpContent::Read(), LwpVirtualLayout::Read(), LwpLayout::Read(), LwpPlacableLayout::Read(), LwpRowLayout::Read(), LwpColumnLayout::Read(), LwpFootnoteNumberOptions::Read(), LwpFootnoteSeparatorOptions::Read(), LwpFribParaNumber::Read(), LwpFribDocVar::Read(), LwpFribPageNumber::Read(), LwpAtomHolder::Read(), LwpColor::Read(), LwpFontTable::Read(), LwpFontNameEntry::Read(), LwpFontNameManager::Read(), LwpFontAttrEntry::Read(), LwpFontAttrManager::Read(), LwpObjectID::Read(), LwpBackgroundStuff::Read(), LwpBorderStuff::Read(), LwpHyphenOptions::Read(), LwpTextLanguage::Read(), LwpLayoutStyle::Read(), LwpLayoutMisc::Read(), LwpJoinStuff::Read(), LwpLineNumberOptions::Read(), LwpSortKey::Read(), LwpSortOption::Read(), LwpTab::Read(), LwpNamedProperties::Read(), LwpAutoRunMacroOptions::Read(), LwpMergeOptions::Read(), LwpUIDocument::Read(), LwpUseWhen::Read(), LwpUserDictFiles::Read(), LwpTextLanguageOverride::Read(), LwpTextAttributeOverride::Read(), LwpKinsokuOptsOverride::Read(), LwpAlignmentOverride::Read(), LwpSpacingCommonOverride::Read(), LwpAmikakeOverride::Read(), LwpNumberingOverride::Read(), LwpOverride::ReadCommon(), LwpObjectID::ReadIndexed(), LwpIndexManager::ReadLeafData(), LwpFrib::ReadModifiers(), LwpIndexManager::ReadObjIndexData(), LwpPara::ReadPropertyList(), LwpIndexManager::ReadRootData(), LwpIndexManager::ReadTimeTable(), LwpAtomHolder::Skip(), LwpVersionManager::Skip(), LwpPrinterInfo::Skip(), and SkipExtra().

◆ QuickReaduInt32()

sal_uInt32 LwpObjectStream::QuickReaduInt32 ( bool *  pFailure = nullptr)

◆ QuickReaduInt8()

sal_uInt8 LwpObjectStream::QuickReaduInt8 ( bool *  pFailure = nullptr)

◆ Read2Buffer()

void LwpObjectStream::Read2Buffer ( )
private

@descr read object data from stream to buffer

Definition at line 84 of file lwpobjstrm.cxx.

References AllocBuffer(), DecompressBuffer(), IO_BUFFERSIZE, m_bCompressed, m_nBufSize, m_nReadPos, m_pContentBuf, m_pStrm, LwpSvStream::Read(), and ReleaseBuffer().

Referenced by LwpObjectStream().

◆ ReadComplete()

void LwpObjectStream::ReadComplete ( )

@descr signal complete to release object buffer

Definition at line 126 of file lwpobjstrm.cxx.

References ReleaseBuffer().

◆ ReleaseBuffer()

void LwpObjectStream::ReleaseBuffer ( )
private

@descr release object buffer

Definition at line 132 of file lwpobjstrm.cxx.

References m_BigBuffer, and m_pContentBuf.

Referenced by Read2Buffer(), ReadComplete(), and ~LwpObjectStream().

◆ remainingSize()

sal_uInt16 LwpObjectStream::remainingSize ( ) const

Definition at line 138 of file lwpobjstrm.cxx.

References m_nBufSize, and m_nReadPos.

◆ Seek()

void LwpObjectStream::Seek ( sal_uInt16  pos)

@descr Seek to pos in object buffer/buffer

Definition at line 169 of file lwpobjstrm.cxx.

References m_nBufSize, m_nReadPos, and pos.

Referenced by LwpTools::IsUnicodePacked().

◆ SeekRel()

void LwpObjectStream::SeekRel ( sal_uInt16  pos)

◆ SkipExtra()

void LwpObjectStream::SkipExtra ( )

@descr skip extra bytes

Definition at line 258 of file lwpobjstrm.cxx.

References QuickReaduInt16().

Referenced by LwpNumericFormatSubset::QuickRead(), LwpNumericFormat::Read(), LwpCellLayout::Read(), LwpContent::Read(), LwpDLVList::Read(), LwpDLNFVList::Read(), LwpDLNFPVList::Read(), LwpVirtualLayout::Read(), LwpMiddleLayout::Read(), LwpLayout::Read(), LwpPlacableLayout::Read(), LwpRowLayout::Read(), LwpColumnLayout::Read(), LwpDLVListHeadTail::Read(), LwpFootnoteNumberOptions::Read(), LwpFootnoteSeparatorOptions::Read(), LwpSLVListHead::Read(), LwpContentHintHead::Read(), LwpFootnoteSeenHead::Read(), LwpNotifyListPersistent::Read(), LwpFontTableEntry::Read(), LwpFontTable::Read(), LwpFontNameEntry::Read(), LwpFontNameManager::Read(), LwpFontAttrEntry::Read(), LwpFontAttrManager::Read(), LwpFontManager::Read(), LwpObjectManager::Read(), LwpNumberManager::Read(), LwpBulletManager::Read(), LwpContentManager::Read(), LwpPieceManager::Read(), LwpFoundry::Read(), LwpBackgroundStuff::Read(), LwpBorderStuff::Read(), LwpHyphenOptions::Read(), LwpTextLanguage::Read(), LwpFrameLink::Read(), LwpAssociatedLayouts::Read(), LwpLayoutStyle::Read(), LwpLayoutMisc::Read(), LwpExternalBorder::Read(), LwpJoinStuff::Read(), LwpLineNumberOptions::Read(), LwpMargins::Read(), LwpShadow::Read(), LwpSortKey::Read(), LwpSortOption::Read(), LwpNamedProperties::Read(), LwpAutoRunMacroOptions::Read(), LwpMergeOptions::Read(), LwpUIDocument::Read(), LwpUseWhen::Read(), LwpUserDictFiles::Read(), LwpTextLanguageOverride::Read(), LwpTextAttributeOverride::Read(), LwpKinsokuOptsOverride::Read(), LwpBulletOverride::Read(), LwpAlignmentOverride::Read(), LwpSpacingCommonOverride::Read(), LwpSpacingOverride::Read(), LwpIndentOverride::Read(), LwpAmikakeOverride::Read(), LwpBackgroundOverride::Read(), LwpBreaksOverride::Read(), LwpCharacterBorderOverride::Read(), LwpNumberingOverride::Read(), LwpParaBorderOverride::Read(), LwpTabOverride::Read(), LwpOverride::ReadCommon(), LwpDLNFVList::ReadName(), LwpVersionManager::Skip(), and LwpPrinterInfo::Skip().

Member Data Documentation

◆ m_bCompressed

bool LwpObjectStream::m_bCompressed
private

Definition at line 93 of file lwpobjstrm.hxx.

Referenced by Read2Buffer().

◆ m_BigBuffer

std::vector<sal_uInt8> LwpObjectStream::m_BigBuffer
private

Definition at line 85 of file lwpobjstrm.hxx.

Referenced by AllocBuffer(), and ReleaseBuffer().

◆ m_nBufSize

sal_uInt16 LwpObjectStream::m_nBufSize
private

Definition at line 90 of file lwpobjstrm.hxx.

Referenced by LwpObjectStream(), QuickRead(), Read2Buffer(), remainingSize(), Seek(), and SeekRel().

◆ m_nReadPos

sal_uInt16 LwpObjectStream::m_nReadPos
private

Definition at line 91 of file lwpobjstrm.hxx.

Referenced by GetPos(), QuickRead(), Read2Buffer(), remainingSize(), Seek(), and SeekRel().

◆ m_pContentBuf

sal_uInt8* LwpObjectStream::m_pContentBuf
private

Definition at line 83 of file lwpobjstrm.hxx.

Referenced by QuickRead(), Read2Buffer(), and ReleaseBuffer().

◆ m_pStrm

LwpSvStream* LwpObjectStream::m_pStrm
private

Definition at line 92 of file lwpobjstrm.hxx.

Referenced by GetStream(), and Read2Buffer().

◆ m_SmallBuffer

sal_uInt8 LwpObjectStream::m_SmallBuffer[100]
private

Definition at line 84 of file lwpobjstrm.hxx.

Referenced by AllocBuffer().


The documentation for this class was generated from the following files: