LibreOffice Module sfx2 (master) 1
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
SfxHTMLParser Class Reference

#include <sfxhtml.hxx>

Inheritance diagram for SfxHTMLParser:
[legend]
Collaboration diagram for SfxHTMLParser:
[legend]

Public Member Functions

bool ParseMapOptions (ImageMap *pImageMap)
 
bool ParseAreaOptions (ImageMap *pImageMap, std::u16string_view rBaseURL, SvMacroItemId nEventMouseOver, SvMacroItemId nEventMouseOut)
 
- Public Member Functions inherited from HTMLParser
 HTMLParser (SvStream &rIn, bool bReadNewDoc=true)
 
virtual SvParserState CallParser () override
 
bool IsNewDoc () const
 
bool IsInHeader () const
 
bool IsReadListing () const
 
bool IsReadXMP () const
 
bool IsReadPRE () const
 
bool IsReadScript () const
 
bool IsReadStyle () const
 
void StartPRE ()
 
void FinishPRE ()
 
HtmlTokenId FilterPRE (HtmlTokenId nToken)
 
void StartListing ()
 
void FinishListing ()
 
HtmlTokenId FilterListing (HtmlTokenId nToken)
 
void StartXMP ()
 
void FinishXMP ()
 
HtmlTokenId FilterXMP (HtmlTokenId nToken)
 
void FinishTextArea ()
 
void FinishPREListingXMP ()
 
HtmlTokenId FilterToken (HtmlTokenId nToken)
 
void ReadRawData (const OUString &rEndToken)
 
void UnescapeToken ()
 
const HTMLOptionsGetOptions (HtmlOptionId const *pNoConvertToken=nullptr)
 
virtual void Continue (HtmlTokenId nToken) override
 
virtual bool ParseMetaOptions (const css::uno::Reference< css::document::XDocumentProperties > &, SvKeyValueIterator *)
 
void ParseScriptOptions (OUString &rLangString, std::u16string_view rBaseURL, HTMLScriptLanguage &rLang, OUString &rSrc, OUString &rLibrary, OUString &rModule)
 
bool SetEncodingByHTTPHeader (SvKeyValueIterator *pHTTPHeader)
 
- Public Member Functions inherited from SvParser< HtmlTokenId >
 SvParser (SvStream &rIn, sal_uInt8 nStackSize=3)
 
virtual SvParserState CallParser ()=0
 
SvParserState GetStatus () const
 
sal_uInt32 GetLineNr () const
 
sal_uInt32 GetLinePos () const
 
void IncLineNr ()
 
sal_uInt32 IncLinePos ()
 
void SetLineNr (sal_uInt32 nlNum)
 
void SetLinePos (sal_uInt32 nlPos)
 
sal_uInt32 GetNextChar ()
 
void RereadLookahead ()
 
bool IsParserWorking () const
 
Link< LinkParamNone *, void > GetAsynchCallLink () const
 
void SaveState (T nToken)
 
void RestoreState ()
 
virtual void Continue (T nToken)
 
void SetSrcEncoding (rtl_TextEncoding eSrcEnc)
 
rtl_TextEncoding GetSrcEncoding () const
 
void SetSwitchToUCS2 (bool bSet)
 
bool IsSwitchToUCS2 () const
 
sal_uInt16 GetCharSize () const
 
GetSaveToken () const
 

Static Public Member Functions

static bool ParseMapOptions (ImageMap *pImageMap, const HTMLOptions &rOptions)
 
static bool ParseAreaOptions (ImageMap *pImageMap, std::u16string_view rBaseURL, const HTMLOptions &rOptions, SvMacroItemId nEventMouseOver, SvMacroItemId nEventMouseOut)
 
static double GetTableDataOptionsValNum (sal_uInt32 &nNumForm, LanguageType &eNumLang, const OUString &aValStr, std::u16string_view aNumStr, SvNumberFormatter &rFormatter)
 
- Static Public Member Functions inherited from HTMLParser
static void RemoveSGMLComment (OUString &rString)
 
static bool InternalImgToPrivateURL (OUString &rURL)
 
static rtl_TextEncoding GetEncodingByHttpHeader (SvKeyValueIterator *pHTTPHeader)
 

Protected Member Functions

 SfxHTMLParser (SvStream &rStream, bool bNewDoc, SfxMedium *pMedium)
 
virtual ~SfxHTMLParser () override
 
void StartFileDownload (const OUString &rURL)
 
bool FinishFileDownload (OUString &rStr)
 
bool ShouldFinishFileDownload () const
 
SfxMediumGetMedium ()
 
const SfxMediumGetMedium () const
 
ScriptType GetScriptType (SvKeyValueIterator *) const
 
const OUString & GetScriptTypeString (SvKeyValueIterator *) const
 
- Protected Member Functions inherited from HTMLParser
HtmlTokenId ScanText (const sal_Unicode cBreak=0U)
 
HtmlTokenId GetNextRawToken ()
 
virtual HtmlTokenId GetNextToken_ () override
 
virtual ~HTMLParser () override
 
void FinishHeader ()
 
void SetNamespace (std::u16string_view rNamespace)
 
virtual void AddMetaUserDefined (OUString const &i_rMetaName)
 
- Protected Member Functions inherited from SvParser< HtmlTokenId >
SkipToken (short nCnt=-1)
 
TokenStackType * GetStackPtr (short nCnt)
 
GetNextToken ()
 
virtual T GetNextToken_ ()=0
 
virtual void NextToken (T nToken)=0
 
virtual ~SvParser () override
 
void ClearTxtConvContext ()
 

Private Member Functions

SAL_DLLPRIVATE void GetScriptType_Impl (SvKeyValueIterator *)
 

Private Attributes

OUString aScriptType
 
SfxMediumpMedium
 
std::unique_ptr< SfxMediumpDLMedium
 
ScriptType eScriptType
 

Additional Inherited Members

- Static Protected Member Functions inherited from HTMLParser
static rtl_TextEncoding GetEncodingByMIME (const OUString &rMime)
 
- Protected Attributes inherited from HTMLParser
OUString sSaveToken
 
- Protected Attributes inherited from SvParser< HtmlTokenId >
SvStreamrInput
 
OUStringBuffer aToken
 
sal_uInt32 nlLineNr
 
sal_uInt32 nlLinePos
 
std::unique_ptr< SvParser_Impl< T > > pImplData
 
tools::Long m_nTokenIndex
 
tools::Long nTokenValue
 
bool bTokenHasValue
 
bool bFuzzing
 
SvParserState eState
 
rtl_TextEncoding eSrcEnc
 
sal_uInt64 nNextChPos
 
sal_uInt32 nNextCh
 
bool bSwitchToUCS2
 
bool bRTF_InTextRead
 

Detailed Description

Definition at line 36 of file sfxhtml.hxx.

Constructor & Destructor Documentation

◆ SfxHTMLParser()

SfxHTMLParser::SfxHTMLParser ( SvStream rStream,
bool  bNewDoc,
SfxMedium pMedium 
)
protected

◆ ~SfxHTMLParser()

SfxHTMLParser::~SfxHTMLParser ( )
overrideprotectedvirtual

Definition at line 77 of file sfxhtml.cxx.

References DBG_ASSERT, and pDLMedium.

Member Function Documentation

◆ FinishFileDownload()

bool SfxHTMLParser::FinishFileDownload ( OUString &  rStr)
protected

◆ GetMedium() [1/2]

SfxMedium * SfxHTMLParser::GetMedium ( )
inlineprotected

Definition at line 94 of file sfxhtml.hxx.

◆ GetMedium() [2/2]

const SfxMedium * SfxHTMLParser::GetMedium ( ) const
inlineprotected

Definition at line 95 of file sfxhtml.hxx.

◆ GetScriptType()

ScriptType SfxHTMLParser::GetScriptType ( SvKeyValueIterator pHTTPHeader) const
protected

Definition at line 299 of file sfxhtml.cxx.

References aScriptType, eScriptType, and GetScriptType_Impl().

◆ GetScriptType_Impl()

void SfxHTMLParser::GetScriptType_Impl ( SvKeyValueIterator pHTTPHeader)
private

◆ GetScriptTypeString()

const OUString & SfxHTMLParser::GetScriptTypeString ( SvKeyValueIterator pHTTPHeader) const
protected

Definition at line 307 of file sfxhtml.cxx.

References aScriptType, and GetScriptType_Impl().

◆ GetTableDataOptionsValNum()

double SfxHTMLParser::GetTableDataOptionsValNum ( sal_uInt32 &  nNumForm,
LanguageType eNumLang,
const OUString &  aValStr,
std::u16string_view  aNumStr,
SvNumberFormatter rFormatter 
)
static

◆ ParseAreaOptions() [1/2]

bool SfxHTMLParser::ParseAreaOptions ( ImageMap pImageMap,
std::u16string_view  rBaseURL,
const HTMLOptions rOptions,
SvMacroItemId  nEventMouseOver,
SvMacroItemId  nEventMouseOut 
)
static

◆ ParseAreaOptions() [2/2]

bool SfxHTMLParser::ParseAreaOptions ( ImageMap pImageMap,
std::u16string_view  rBaseURL,
SvMacroItemId  nEventMouseOver,
SvMacroItemId  nEventMouseOut 
)
inline

Definition at line 102 of file sfxhtml.hxx.

References HTMLParser::GetOptions(), and ParseAreaOptions().

◆ ParseMapOptions() [1/2]

bool SfxHTMLParser::ParseMapOptions ( ImageMap pImageMap)
inline

Definition at line 58 of file sfxhtml.hxx.

References HTMLParser::GetOptions().

◆ ParseMapOptions() [2/2]

bool SfxHTMLParser::ParseMapOptions ( ImageMap pImageMap,
const HTMLOptions rOptions 
)
static

◆ ShouldFinishFileDownload()

bool SfxHTMLParser::ShouldFinishFileDownload ( ) const
inlineprotected

Definition at line 92 of file sfxhtml.hxx.

◆ StartFileDownload()

void SfxHTMLParser::StartFileDownload ( const OUString &  rURL)
protected

Definition at line 222 of file sfxhtml.cxx.

References DBG_ASSERT, pDLMedium, and SFX_STREAM_READONLY.

Member Data Documentation

◆ aScriptType

OUString SfxHTMLParser::aScriptType
private

Definition at line 38 of file sfxhtml.hxx.

Referenced by GetScriptType(), GetScriptType_Impl(), and GetScriptTypeString().

◆ eScriptType

ScriptType SfxHTMLParser::eScriptType
private

Definition at line 43 of file sfxhtml.hxx.

Referenced by GetScriptType(), and GetScriptType_Impl().

◆ pDLMedium

std::unique_ptr<SfxMedium> SfxHTMLParser::pDLMedium
private

Definition at line 41 of file sfxhtml.hxx.

Referenced by FinishFileDownload(), StartFileDownload(), and ~SfxHTMLParser().

◆ pMedium

SfxMedium* SfxHTMLParser::pMedium
private

Definition at line 40 of file sfxhtml.hxx.


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