LibreOffice Module dbaccess (master) 1
|
#include <RtfReader.hxx>
Public Member Functions | |
ORTFReader (SvStream &rIn, const SharedConnection &_rxConnection, const css::uno::Reference< css::util::XNumberFormatter > &_rxNumberF, const css::uno::Reference< css::uno::XComponentContext > &_rxContext) | |
ORTFReader (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 |
![]() | |
SvRTFParser (SvStream &rIn, sal_uInt8 nStackSize=3) | |
virtual SvParserState | CallParser () override |
virtual void | Continue (int nToken) override |
![]() | |
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 |
![]() | |
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 | |
bool | CreateTable (int nToken) |
virtual void | NextToken (int nToken) override |
virtual TypeSelectionPageFactory | getTypeSelectionPageFactory () override |
virtual | ~ORTFReader () override |
Private Attributes | |
std::vector< Color > | m_vecColor |
Additional Inherited Members | |
![]() | |
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 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) |
![]() | |
sal_Unicode | GetHexValue () |
void | ScanText () |
void | SkipGroup () |
virtual int | GetNextToken_ () override |
void | ReadUnknownData () |
void | ReadBitmapData () |
virtual | ~SvRTFParser () override |
rtl_TextEncoding | GetCodeSet () const |
void | SetEncoding (rtl_TextEncoding eEnc) |
![]() | |
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 () |
![]() | |
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 () |
![]() | |
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 |
![]() | |
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 29 of file RtfReader.hxx.
|
overrideprivatevirtual |
Definition at line 72 of file RtfReader.cxx.
dbaui::ORTFReader::ORTFReader | ( | SvStream & | rIn, |
const SharedConnection & | _rxConnection, | ||
const css::uno::Reference< css::util::XNumberFormatter > & | _rxNumberF, | ||
const css::uno::Reference< css::uno::XComponentContext > & | _rxContext | ||
) |
dbaui::ORTFReader::ORTFReader | ( | 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 SvRTFParser.
Definition at line 76 of file RtfReader.cxx.
References SvRTFParser::CallParser(), dbaui::ODatabaseExport::m_bFoundTable, dbaui::ODatabaseExport::m_pColumnList, dbaui::ODatabaseExport::m_pInfoMap, SvStream::ResetError(), SvParser< int >::rInput, SvStream::Seek(), dbaui::ODatabaseExport::SetColumnTypes(), and STREAM_SEEK_TO_BEGIN.
|
private |
Definition at line 222 of file RtfReader.cxx.
References Any, SvParser< int >::aToken, dbaui::ODatabaseExport::CreateDefaultColumn(), VCLUnoHelper::CreateFontDescriptor(), DBA_RES, SvParser< int >::eState, dbaui::ODatabaseExport::executeWizard(), SvParser< int >::GetNextToken(), Application::GetSettings(), dbaui::ODatabaseExport::isCheckEnabled(), dbaui::ODatabaseExport::m_bAppendFirstLine, dbaui::ODatabaseExport::m_bFoundTable, dbaui::ODatabaseExport::m_bInTbl, dbaui::ODatabaseExport::m_vDestVector, m_vecColor, dbaui::ODatabaseExport::m_xTable, dbaui::ODatabaseExport::m_xTables, nToken, RTF_B, RTF_CELL, RTF_CF, RTF_I, RTF_INTBL, RTF_SINGLECHAR, RTF_STRIKE, RTF_TEXTTOKEN, RTF_TROWD, RTF_UL, RTF_UNKNOWNCONTROL, RTF_UNKNOWNDATA, and comphelper::string::strip().
Referenced by NextToken().
|
overrideprivatevirtual |
Implements dbaui::ODatabaseExport.
Definition at line 304 of file RtfReader.cxx.
References dbaui::OWizRTFExtend::Create().
|
overrideprivatevirtual |
Definition at line 89 of file RtfReader.cxx.
References dbaui::ODatabaseExport::adjustFormat(), SvParser< int >::aToken, CreateTable(), dbaui::ODatabaseExport::eraseTokens(), SvParser< int >::eState, SvParser< int >::GetNextToken(), Color::GetRGBColor(), 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, dbaui::ODatabaseExport::m_nRowCount, dbaui::ODatabaseExport::m_nRows, dbaui::ODatabaseExport::m_pUpdateHelper, dbaui::ODatabaseExport::m_sTextToken, m_vecColor, dbaui::ODatabaseExport::m_xConnection, dbaui::ODatabaseExport::m_xTable, nToken, SvParser< int >::nTokenValue, SvStream::ResetError(), SvParser< int >::rInput, RTF_BLUE, RTF_CELL, RTF_COLORTBL, RTF_GREEN, RTF_INTBL, RTF_RED, RTF_ROW, RTF_SINGLECHAR, RTF_TEXTTOKEN, RTF_TROWD, SvStream::Seek(), Color::SetBlue(), Color::SetGreen(), Color::SetRed(), dbaui::ODatabaseExport::showErrorDialog(), SvParser< int >::SkipToken(), and SvStream::Tell().
|
private |
Definition at line 31 of file RtfReader.hxx.
Referenced by CreateTable(), and NextToken().