|
LibreOffice Module dbaccess (master) 1
|
#include <HtmlReader.hxx>
Public Member Functions | |
| OHTMLReader (SvStream &rIn, const SharedConnection &_rxConnection, const css::uno::Reference< css::util::XNumberFormatter > &_rxNumberF, const css::uno::Reference< css::uno::XComponentContext > &_rxContext) | |
| OHTMLReader (SvStream &rIn, sal_Int32 nRows, TPositions &&_rColumnPositions, const css::uno::Reference< css::util::XNumberFormatter > &_rxNumberF, const css::uno::Reference< css::uno::XComponentContext > &_rxContext, const TColumnVector *rList, const OTypeInfoMap *_pInfoMap, bool _bAutoIncrementEnabled) | |
| virtual SvParserState | CallParser () override |
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 HTMLOptions & | GetOptions (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 |
| T | GetSaveToken () const |
Public Member Functions inherited from dbaui::ODatabaseExport | |
| ODatabaseExport (const SharedConnection &_rxConnection, const css::uno::Reference< css::util::XNumberFormatter > &_rxNumberF, const css::uno::Reference< css::uno::XComponentContext > &_rxContext, SvStream &_rInputStream) | |
| ODatabaseExport (sal_Int32 nRows, TPositions &&_rColumnPositions, const css::uno::Reference< css::util::XNumberFormatter > &_rxNumberF, const css::uno::Reference< css::uno::XComponentContext > &_rxContext, const TColumnVector *rList, const OTypeInfoMap *_pInfoMap, bool _bAutoIncrementEnabled, SvStream &_rInputStream) | |
| void | SetColumnTypes (const TColumnVector *rList, const OTypeInfoMap *_pInfoMap) |
| void | SetTableName (const OUString &_sTableName) |
| void | enableCheckOnly () |
| bool | isCheckEnabled () const |
Private Member Functions | |
| virtual void | NextToken (HtmlTokenId nToken) override |
| bool | CreateTable (HtmlTokenId nToken) |
| virtual TypeSelectionPageFactory | getTypeSelectionPageFactory () override |
| void | TableDataOn (SvxCellHorJustify &eVal) |
| void | TableFontOn (css::awt::FontDescriptor &_rFont, Color &_rTextColor) |
| sal_Int16 | GetWidthPixel (const HTMLOption &rOption) |
| void | setTextEncoding () |
| void | fetchOptions () |
| virtual | ~OHTMLReader () override |
Private Attributes | |
| OUString | m_sCurrent |
| sal_Int32 | m_nTableCount |
| sal_Int16 | m_nColumnWidth |
| maximum column width More... | |
Additional Inherited Members | |
Public Types inherited from dbaui::ODatabaseExport | |
| typedef std::map< OUString, OFieldDescription *, ::comphelper::UStringMixLess > | TColumns |
| typedef std::vector< TColumns::const_iterator > | TColumnVector |
| typedef std::vector< std::pair< sal_Int32, sal_Int32 > > | TPositions |
Static Public Member Functions inherited from HTMLParser | |
| static void | RemoveSGMLComment (OUString &rString) |
| static bool | InternalImgToPrivateURL (OUString &rURL) |
| static rtl_TextEncoding | GetEncodingByHttpHeader (SvKeyValueIterator *pHTTPHeader) |
Static Public Member Functions inherited from dbaui::ODatabaseExport | |
| static css::uno::Reference< css::sdbc::XPreparedStatement > | createPreparedStatement (const css::uno::Reference< css::sdbc::XDatabaseMetaData > &_xMetaData, const css::uno::Reference< css::beans::XPropertySet > &_xDestTable, const TPositions &_rvColumnPositions) |
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 > | |
| T | SkipToken (short nCnt=-1) |
| TokenStackType * | GetStackPtr (short nCnt) |
| T | GetNextToken () |
| virtual T | GetNextToken_ ()=0 |
| virtual void | NextToken (T nToken)=0 |
| virtual | ~SvParser () override |
| void | ClearTxtConvContext () |
Protected Member Functions inherited from dbaui::ODatabaseExport | |
| virtual TypeSelectionPageFactory | getTypeSelectionPageFactory ()=0 |
| void | CreateDefaultColumn (const OUString &_rColumnName) |
| sal_Int16 | CheckString (const OUString &aToken, sal_Int16 _nOldNumberFormat) |
| void | adjustFormat () |
| void | eraseTokens () |
| void | insertValueIntoColumn () |
| void | createRowSet () |
| void | showErrorDialog (const css::sdbc::SQLException &e) |
| void | ensureFormatter () |
| bool | executeWizard (const OUString &_sTableName, const css::uno::Any &_aTextColor, const css::awt::FontDescriptor &_rFont) |
| executeWizard calls a wizard to create/append data More... | |
| virtual | ~ODatabaseExport () |
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 > | |
| SvStream & | rInput |
| 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 |
Protected Attributes inherited from dbaui::ODatabaseExport | |
| TPositions | m_vColumnPositions |
| columns to be used More... | |
| std::vector< sal_Int32 > | m_vColumnTypes |
| ColumnTypes for faster access. More... | |
| std::vector< sal_Int32 > | m_vColumnSize |
| std::vector< sal_Int16 > | m_vNumberFormat |
| css::lang::Locale | m_aLocale |
| TColumns | m_aDestColumns |
| container for new created columns More... | |
| TColumnVector | m_vDestVector |
| css::uno::Reference< css::beans::XPropertySet > | m_xTable |
| dest table More... | |
| css::uno::Reference< css::container::XNameAccess > | m_xTables |
| container More... | |
| SharedConnection | m_xConnection |
| dest conn More... | |
| std::shared_ptr< IUpdateHelper > | m_pUpdateHelper |
| css::uno::Reference< css::util::XNumberFormatter > | m_xFormatter |
| a number formatter working with the connection's NumberFormatsSupplier More... | |
| css::uno::Reference< css::uno::XComponentContext > | m_xContext |
| css::util::Date | m_aNullDate |
| SvNumberFormatter * | m_pFormatter |
| SvStream & | m_rInputStream |
| OUString | m_sDefaultTableName |
| for saving the selected tablename More... | |
| OUString | m_sTextToken |
| cell content More... | |
| OUString | m_sNumToken |
| SDNUM value. More... | |
| TOTypeInfoSP | m_pTypeInfo |
| contains the default type More... | |
| const TColumnVector * | m_pColumnList |
| const OTypeInfoMap * | m_pInfoMap |
| sal_Int32 | m_nColumnPos |
| current column position More... | |
| sal_Int32 | m_nRows |
| number of rows to be searched More... | |
| sal_Int32 | m_nRowCount |
| current count of rows More... | |
| bool | m_bError |
| error and termination code More... | |
| bool | m_bInTbl |
| true, if parser is in RTF table More... | |
| bool | m_bHead |
| true, if the header hasn't been read yet More... | |
| bool | m_bDontAskAgain |
| if there is an error when pasting, don't show it again More... | |
| bool | m_bIsAutoIncrement |
| if PKey is set by user More... | |
| bool | m_bFoundTable |
| set to true when a table was found More... | |
| bool | m_bCheckOnly |
| bool | m_bAppendFirstLine |
Definition at line 31 of file HtmlReader.hxx.
|
overrideprivatevirtual |
Definition at line 83 of file HtmlReader.cxx.
| dbaui::OHTMLReader::OHTMLReader | ( | SvStream & | rIn, |
| const SharedConnection & | _rxConnection, | ||
| const css::uno::Reference< css::util::XNumberFormatter > & | _rxNumberF, | ||
| const css::uno::Reference< css::uno::XComponentContext > & | _rxContext | ||
| ) |
| dbaui::OHTMLReader::OHTMLReader | ( | SvStream & | rIn, |
| sal_Int32 | nRows, | ||
| TPositions && | _rColumnPositions, | ||
| const css::uno::Reference< css::util::XNumberFormatter > & | _rxNumberF, | ||
| const css::uno::Reference< css::uno::XComponentContext > & | _rxContext, | ||
| const TColumnVector * | rList, | ||
| const OTypeInfoMap * | _pInfoMap, | ||
| bool | _bAutoIncrementEnabled | ||
| ) |
|
overridevirtual |
Reimplemented from HTMLParser.
Definition at line 87 of file HtmlReader.cxx.
References HTMLParser::CallParser(), dbaui::ODatabaseExport::m_bFoundTable, dbaui::ODatabaseExport::m_pColumnList, dbaui::ODatabaseExport::m_pInfoMap, SvStream::ResetError(), SvParser< HtmlTokenId >::rInput, SvStream::Seek(), dbaui::ODatabaseExport::SetColumnTypes(), and STREAM_SEEK_TO_BEGIN.
|
private |
Definition at line 361 of file HtmlReader.cxx.
References Any, SvParser< HtmlTokenId >::aToken, dbaui::ODatabaseExport::CreateDefaultColumn(), VCLUnoHelper::CreateFontDescriptor(), DBA_RES, dbaui::ODatabaseExport::executeWizard(), SvParser< HtmlTokenId >::GetNextToken(), Application::GetSettings(), dbaui::ODatabaseExport::isCheckEnabled(), dbaui::ODatabaseExport::m_bAppendFirstLine, dbaui::ODatabaseExport::m_bFoundTable, dbaui::ODatabaseExport::m_bInTbl, m_sCurrent, dbaui::ODatabaseExport::m_sTextToken, dbaui::ODatabaseExport::m_vDestVector, dbaui::ODatabaseExport::m_xTable, dbaui::ODatabaseExport::m_xTables, nToken, comphelper::string::strip(), TableDataOn(), and TableFontOn().
Referenced by NextToken().
|
private |
Definition at line 252 of file HtmlReader.cxx.
References HTMLParser::GetOptions(), dbaui::ODatabaseExport::m_bInTbl, and dbaui::ODatabaseExport::m_sNumToken.
Referenced by NextToken().
|
overrideprivatevirtual |
Implements dbaui::ODatabaseExport.
Definition at line 476 of file HtmlReader.cxx.
References dbaui::OWizHTMLExtend::Create().
|
private |
Definition at line 341 of file HtmlReader.cxx.
References HTMLOption::GetNumber(), HTMLOption::GetString(), and m_nColumnWidth.
Referenced by NextToken().
|
overrideprivatevirtual |
Definition at line 99 of file HtmlReader.cxx.
References dbaui::ODatabaseExport::adjustFormat(), SvParser< HtmlTokenId >::aToken, CreateTable(), dbaui::ODatabaseExport::eraseTokens(), fetchOptions(), SvParser< HtmlTokenId >::GetNextToken(), HTMLParser::GetOptions(), GetWidthPixel(), dbaui::ODatabaseExport::insertValueIntoColumn(), utl::SharedUNOComponent< class INTERFACE, class COMPONENT >::is(), dbaui::ODatabaseExport::m_bAppendFirstLine, dbaui::ODatabaseExport::m_bError, dbaui::ODatabaseExport::m_bHead, dbaui::ODatabaseExport::m_bInTbl, dbaui::ODatabaseExport::m_bIsAutoIncrement, dbaui::ODatabaseExport::m_nColumnPos, m_nColumnWidth, dbaui::ODatabaseExport::m_nRowCount, dbaui::ODatabaseExport::m_nRows, m_nTableCount, dbaui::ODatabaseExport::m_pUpdateHelper, m_sCurrent, dbaui::ODatabaseExport::m_sTextToken, dbaui::ODatabaseExport::m_xConnection, dbaui::ODatabaseExport::m_xTable, nToken, SvParser< HtmlTokenId >::rInput, SvStream::Seek(), setTextEncoding(), dbaui::ODatabaseExport::showErrorDialog(), and SvStream::Tell().
|
private |
Definition at line 471 of file HtmlReader.cxx.
References HTMLParser::ParseMetaOptions().
Referenced by NextToken().
|
private |
Definition at line 268 of file HtmlReader.cxx.
References HTMLParser::GetOptions(), OOO_STRING_SVTOOLS_HTML_AL_center, OOO_STRING_SVTOOLS_HTML_AL_left, and OOO_STRING_SVTOOLS_HTML_AL_right.
Referenced by CreateTable().
|
private |
Definition at line 293 of file HtmlReader.cxx.
References DBAUI_HTML_FONTSIZES, HTMLParser::GetOptions(), Color::GetRGBColor(), o3tl::getToken(), nPos, and comphelper::string::strip().
Referenced by CreateTable().
|
private |
maximum column width
Definition at line 35 of file HtmlReader.hxx.
Referenced by GetWidthPixel(), and NextToken().
|
private |
Definition at line 34 of file HtmlReader.hxx.
Referenced by NextToken().
|
private |
Definition at line 33 of file HtmlReader.hxx.
Referenced by CreateTable(), and NextToken().