LibreOffice Module svtools (master) 1
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
svt::TemplateFolderCacheImpl Class Reference

Public Member Functions

 TemplateFolderCacheImpl (bool _bAutoStoreState)
 
 ~TemplateFolderCacheImpl ()
 
bool needsUpdate ()
 
void storeState ()
 

Private Member Functions

bool openCacheStream (bool _bForRead)
 
void closeCacheStream ()
 
bool readPreviousState ()
 read the state of the dirs from the cache file More...
 
bool readCurrentState ()
 read the current state of the dirs More...
 
bool implReadFolder (const ::rtl::Reference< TemplateContent > &_rxRoot)
 
const uno::Reference< util::XOfficeInstallationDirectories > & getOfficeInstDirs ()
 

Static Private Member Functions

static OUString implParseSmart (const OUString &_rPath)
 
static sal_Int32 getMagicNumber ()
 
static void normalize (TemplateFolderContent &_rState)
 
static bool equalStates (const TemplateFolderContent &_rLHS, const TemplateFolderContent &_rRHS)
 

Private Attributes

TemplateFolderContent m_aPreviousState
 
TemplateFolderContent m_aCurrentState
 
std::mutex m_aMutex
 
uno::Reference< util::XOfficeInstallationDirectories > m_xOfficeInstDirs
 
std::unique_ptr< SvStreamm_pCacheStream
 
bool m_bNeedsUpdate: 1
 
bool m_bKnowState: 1
 
bool m_bValidCurrentState: 1
 
bool m_bAutoStoreState: 1
 

Detailed Description

Definition at line 379 of file templatefoldercache.cxx.

Constructor & Destructor Documentation

◆ TemplateFolderCacheImpl()

svt::TemplateFolderCacheImpl::TemplateFolderCacheImpl ( bool  _bAutoStoreState)
explicit

Definition at line 426 of file templatefoldercache.cxx.

◆ ~TemplateFolderCacheImpl()

svt::TemplateFolderCacheImpl::~TemplateFolderCacheImpl ( )

Member Function Documentation

◆ closeCacheStream()

void svt::TemplateFolderCacheImpl::closeCacheStream ( )
private

Definition at line 523 of file templatefoldercache.cxx.

References m_pCacheStream.

Referenced by needsUpdate(), openCacheStream(), and ~TemplateFolderCacheImpl().

◆ equalStates()

bool svt::TemplateFolderCacheImpl::equalStates ( const TemplateFolderContent _rLHS,
const TemplateFolderContent _rRHS 
)
staticprivate

Definition at line 460 of file templatefoldercache.cxx.

Referenced by needsUpdate().

◆ getMagicNumber()

sal_Int32 svt::TemplateFolderCacheImpl::getMagicNumber ( )
staticprivate

Definition at line 445 of file templatefoldercache.cxx.

Referenced by readPreviousState(), and storeState().

◆ getOfficeInstDirs()

const uno::Reference< util::XOfficeInstallationDirectories > & svt::TemplateFolderCacheImpl::getOfficeInstDirs ( )
private

◆ implParseSmart()

OUString svt::TemplateFolderCacheImpl::implParseSmart ( const OUString &  _rPath)
staticprivate

◆ implReadFolder()

bool svt::TemplateFolderCacheImpl::implReadFolder ( const ::rtl::Reference< TemplateContent > &  _rxRoot)
private

◆ needsUpdate()

bool svt::TemplateFolderCacheImpl::needsUpdate ( )

◆ normalize()

void svt::TemplateFolderCacheImpl::normalize ( TemplateFolderContent _rState)
staticprivate

Definition at line 454 of file templatefoldercache.cxx.

Referenced by readCurrentState(), and readPreviousState().

◆ openCacheStream()

bool svt::TemplateFolderCacheImpl::openCacheStream ( bool  _bForRead)
private

◆ readCurrentState()

bool svt::TemplateFolderCacheImpl::readCurrentState ( )
private

◆ readPreviousState()

bool svt::TemplateFolderCacheImpl::readPreviousState ( )
private

read the state of the dirs from the cache file

Definition at line 643 of file templatefoldercache.cxx.

References DBG_ASSERT, getMagicNumber(), getOfficeInstDirs(), m_aPreviousState, m_pCacheStream, nMagic, and normalize().

Referenced by needsUpdate().

◆ storeState()

void svt::TemplateFolderCacheImpl::storeState ( )

Member Data Documentation

◆ m_aCurrentState

TemplateFolderContent svt::TemplateFolderCacheImpl::m_aCurrentState
private

Definition at line 383 of file templatefoldercache.cxx.

Referenced by needsUpdate(), readCurrentState(), and storeState().

◆ m_aMutex

std::mutex svt::TemplateFolderCacheImpl::m_aMutex
private

Definition at line 385 of file templatefoldercache.cxx.

Referenced by getOfficeInstDirs().

◆ m_aPreviousState

TemplateFolderContent svt::TemplateFolderCacheImpl::m_aPreviousState
private

Definition at line 382 of file templatefoldercache.cxx.

Referenced by needsUpdate(), and readPreviousState().

◆ m_bAutoStoreState

bool svt::TemplateFolderCacheImpl::m_bAutoStoreState
private

Definition at line 393 of file templatefoldercache.cxx.

Referenced by ~TemplateFolderCacheImpl().

◆ m_bKnowState

bool svt::TemplateFolderCacheImpl::m_bKnowState
private

Definition at line 391 of file templatefoldercache.cxx.

Referenced by needsUpdate().

◆ m_bNeedsUpdate

bool svt::TemplateFolderCacheImpl::m_bNeedsUpdate
private

Definition at line 390 of file templatefoldercache.cxx.

Referenced by needsUpdate().

◆ m_bValidCurrentState

bool svt::TemplateFolderCacheImpl::m_bValidCurrentState
private

Definition at line 392 of file templatefoldercache.cxx.

Referenced by readCurrentState(), storeState(), and ~TemplateFolderCacheImpl().

◆ m_pCacheStream

std::unique_ptr<SvStream> svt::TemplateFolderCacheImpl::m_pCacheStream
private

◆ m_xOfficeInstDirs

uno::Reference< util::XOfficeInstallationDirectories > svt::TemplateFolderCacheImpl::m_xOfficeInstDirs
private

Definition at line 387 of file templatefoldercache.cxx.

Referenced by getOfficeInstDirs().


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