LibreOffice Module xmloff (master) 1
Public Member Functions | Private Member Functions | Private Attributes | List of all members
SvXMLNumFmtExport Class Referencefinal

#include <xmlnumfe.hxx>

Collaboration diagram for SvXMLNumFmtExport:
[legend]

Public Member Functions

 SvXMLNumFmtExport (SvXMLExport &rExport, const css::uno::Reference< css::util::XNumberFormatsSupplier > &rSupp)
 
 SvXMLNumFmtExport (SvXMLExport &rExport, const css::uno::Reference< css::util::XNumberFormatsSupplier > &rSupp, OUString sPrefix)
 
 ~SvXMLNumFmtExport ()
 
void Export (bool bIsAutoStyle)
 
void SetUsed (sal_uInt32 nKey)
 
OUString GetStyleName (sal_uInt32 nKey)
 
css::uno::Sequence< sal_Int32 > GetWasUsed () const
 
void SetWasUsed (const css::uno::Sequence< sal_Int32 > &rWasUsed)
 
sal_uInt32 ForceSystemLanguage (sal_uInt32 nKey)
 obtain number format with system language for a given key More...
 

Private Member Functions

SAL_DLLPRIVATE void AddCalendarAttr_Impl (const OUString &rCalendar)
 
SAL_DLLPRIVATE void AddStyleAttr_Impl (bool bLong)
 
SAL_DLLPRIVATE void AddLanguageAttr_Impl (LanguageType nLang)
 
SAL_DLLPRIVATE void AddToTextElement_Impl (std::u16string_view rString)
 
SAL_DLLPRIVATE void FinishTextElement_Impl (bool bUseExtensionNS=false)
 
SAL_DLLPRIVATE void WriteColorElement_Impl (const Color &rColor)
 
SAL_DLLPRIVATE void WriteIntegerElement_Impl (sal_Int32 nInteger, sal_Int32 nBlankInteger, bool bGrouping)
 
SAL_DLLPRIVATE void WriteEmbeddedEntries_Impl (const SvXMLEmbeddedTextEntryArr &rEmbeddedEntries)
 
SAL_DLLPRIVATE void WriteNumberElement_Impl (sal_Int32 nDecimals, sal_Int32 nMinDecimals, sal_Int32 nInteger, sal_Int32 nBlankInteger, const OUString &rDashStr, bool bGrouping, sal_Int32 nTrailingThousands, const SvXMLEmbeddedTextEntryArr &rEmbeddedEntries)
 
SAL_DLLPRIVATE void WriteScientificElement_Impl (sal_Int32 nDecimals, sal_Int32 nMinDecimals, sal_Int32 nInteger, sal_Int32 nBlankInteger, bool bGrouping, sal_Int32 nExp, sal_Int32 nExpInterval, bool bExpSign, const SvXMLEmbeddedTextEntryArr &rEmbeddedEntries)
 
SAL_DLLPRIVATE void WriteFractionElement_Impl (sal_Int32 nInteger, sal_Int32 nBlankInteger, bool bGrouping, const SvNumberformat &rFormat, sal_uInt16 nPart)
 
SAL_DLLPRIVATE void WriteCurrencyElement_Impl (const OUString &rString, std::u16string_view rExt)
 
SAL_DLLPRIVATE void WriteBooleanElement_Impl ()
 
SAL_DLLPRIVATE void WriteTextContentElement_Impl ()
 
SAL_DLLPRIVATE void WriteDayElement_Impl (const OUString &rCalendar, bool bLong)
 
SAL_DLLPRIVATE void WriteMonthElement_Impl (const OUString &rCalendar, bool bLong, bool bText)
 
SAL_DLLPRIVATE void WriteYearElement_Impl (const OUString &rCalendar, bool bLong)
 
SAL_DLLPRIVATE void WriteEraElement_Impl (const OUString &rCalendar, bool bLong)
 
SAL_DLLPRIVATE void WriteDayOfWeekElement_Impl (const OUString &rCalendar, bool bLong)
 
SAL_DLLPRIVATE void WriteWeekElement_Impl (const OUString &rCalendar)
 
SAL_DLLPRIVATE void WriteQuarterElement_Impl (const OUString &rCalendar, bool bLong)
 
SAL_DLLPRIVATE void WriteHoursElement_Impl (bool bLong)
 
SAL_DLLPRIVATE void WriteMinutesElement_Impl (bool bLong)
 
SAL_DLLPRIVATE void WriteSecondsElement_Impl (bool bLong, sal_uInt16 nDecimals)
 
SAL_DLLPRIVATE void WriteAMPMElement_Impl ()
 
SAL_DLLPRIVATE void WriteMapElement_Impl (sal_Int32 nOp, double fLimit, sal_Int32 nKey, sal_Int32 nPart)
 
SAL_DLLPRIVATE void WriteRepeatedElement_Impl (sal_Unicode ch)
 
SAL_DLLPRIVATE bool WriteTextWithCurrency_Impl (const OUString &rString, const css::lang::Locale &rLocale)
 
SAL_DLLPRIVATE void ExportPart_Impl (const SvNumberformat &rFormat, sal_uInt32 nKey, sal_uInt32 nRealKey, sal_uInt16 nPart, bool bDefPart)
 
SAL_DLLPRIVATE void ExportFormat_Impl (const SvNumberformat &rFormat, sal_uInt32 nKey, sal_uInt32 nRealKey)
 

Private Attributes

SvXMLExportm_rExport
 
OUString m_sPrefix
 
SvNumberFormatterm_pFormatter
 
OUStringBuffer m_sTextContent
 
bool m_bHasText
 
std::unique_ptr< SvXMLNumUsedList_Implm_pUsedList
 
std::unique_ptr< LocaleDataWrapperm_pLocaleData
 

Detailed Description

Definition at line 47 of file xmlnumfe.hxx.

Constructor & Destructor Documentation

◆ SvXMLNumFmtExport() [1/2]

SvXMLNumFmtExport::SvXMLNumFmtExport ( SvXMLExport rExport,
const css::uno::Reference< css::util::XNumberFormatsSupplier > &  rSupp 
)

References Export.

◆ SvXMLNumFmtExport() [2/2]

SvXMLNumFmtExport::SvXMLNumFmtExport ( SvXMLExport rExport,
const css::uno::Reference< css::util::XNumberFormatsSupplier > &  rSupp,
OUString  sPrefix 
)

◆ ~SvXMLNumFmtExport()

SvXMLNumFmtExport::~SvXMLNumFmtExport ( )

Definition at line 269 of file xmlnumfe.cxx.

Member Function Documentation

◆ AddCalendarAttr_Impl()

void SvXMLNumFmtExport::AddCalendarAttr_Impl ( const OUString &  rCalendar)
private

◆ AddLanguageAttr_Impl()

void SvXMLNumFmtExport::AddLanguageAttr_Impl ( LanguageType  nLang)
private

◆ AddStyleAttr_Impl()

void SvXMLNumFmtExport::AddStyleAttr_Impl ( bool  bLong)
private

◆ AddToTextElement_Impl()

void SvXMLNumFmtExport::AddToTextElement_Impl ( std::u16string_view  rString)
private

Definition at line 310 of file xmlnumfe.cxx.

References m_bHasText, and m_sTextContent.

Referenced by ExportPart_Impl(), and WriteTextWithCurrency_Impl().

◆ Export()

void SvXMLNumFmtExport::Export ( bool  bIsAutoStyle)

◆ ExportFormat_Impl()

void SvXMLNumFmtExport::ExportFormat_Impl ( const SvNumberformat rFormat,
sal_uInt32  nKey,
sal_uInt32  nRealKey 
)
private

◆ ExportPart_Impl()

void SvXMLNumFmtExport::ExportPart_Impl ( const SvNumberformat rFormat,
sal_uInt32  nKey,
sal_uInt32  nRealKey,
sal_uInt16  nPart,
bool  bDefPart 
)
private

for the default part, pass the conditions from the other parts!

move to implementation of Write... methods?

difference between '.' and ',' is lost here

must be different from short automatic format but should still be empty (meaning automatic)

first letter of month name, no attribute available

R acts as EE, no attribute available

distinguish EE and R

RR acts as GGGEE, no attribute available

distinguish GG and GGG and RR

Definition at line 1025 of file xmlnumfe.cxx.

References SvXMLExport::AddAttribute(), AddLanguageAttr_Impl(), AddToTextElement_Impl(), LanguageTag::convertToLocale(), eType, FinishTextElement_Impl(), SvNumberformat::GetColor(), SvNumberformat::GetComment(), SvNumberFormatter::GetComponentContext(), SvNumberformat::GetConditions(), SvNumberformat::GetFormatstring(), SvNumberFormatter::GetIndexTableOffset(), LanguageTag::getIsoLanguageScriptCountry(), SvNumberformat::GetLanguage(), SvNumberformat::GetNatNumXml(), SvNumberformat::GetNumForInfo(), SvNumberformat::GetNumForNumberElementCount(), SvNumberformat::GetNumForString(), SvNumberformat::GetNumForType(), SvXMLExport::getSaneDefaultVersion(), SvNumberformat::GetType(), SvNumberformat::HasTextFormat(), i, SvNumberformat::InsertBlanks(), lcl_CreateStyleName(), lcl_GetDefaultCalendar(), lcl_IsDefaultDateFormat(), lcl_IsInEmbedded(), m_bHasText, m_pFormatter, m_pLocaleData, m_rExport, m_sPrefix, m_sTextContent, NF_BOOLEAN, NF_CURRENCY_1000DEC2, NF_CURRENCY_1000DEC2_CCC, NF_CURRENCY_1000DEC2_DASHED, NF_CURRENCY_1000DEC2_RED, NF_CURRENCY_1000INT, NF_CURRENCY_1000INT_RED, NF_DATE_SYS_DDMMM, NF_DATE_SYS_DDMMYY, NF_DATE_SYS_DDMMYYYY, NF_DATE_SYS_DMMMMYYYY, NF_DATE_SYS_DMMMYY, NF_DATE_SYS_DMMMYYYY, NF_DATE_SYS_MMYY, NF_DATE_SYS_NNDMMMMYYYY, NF_DATE_SYS_NNDMMMYY, NF_DATE_SYS_NNNNDMMMMYYYY, NF_DATE_SYSTEM_LONG, NF_DATE_SYSTEM_SHORT, NF_DATETIME_SYS_DDMMYYYY_HHMM, NF_DATETIME_SYS_DDMMYYYY_HHMMSS, NF_DATETIME_SYSTEM_SHORT_HHMM, NF_KEY_AAA, NF_KEY_AAAA, NF_KEY_AMPM, NF_KEY_AP, NF_KEY_BOOLEAN, NF_KEY_CCC, NF_KEY_D, NF_KEY_DD, NF_KEY_DDD, NF_KEY_DDDD, NF_KEY_EC, NF_KEY_EEC, NF_KEY_G, NF_KEY_GENERAL, NF_KEY_GG, NF_KEY_GGG, NF_KEY_H, NF_KEY_HH, NF_KEY_M, NF_KEY_MI, NF_KEY_MM, NF_KEY_MMI, NF_KEY_MMM, NF_KEY_MMMM, NF_KEY_MMMMM, NF_KEY_NN, NF_KEY_NNN, NF_KEY_NNNN, NF_KEY_Q, NF_KEY_QQ, NF_KEY_R, NF_KEY_RR, NF_KEY_S, NF_KEY_SS, NF_KEY_WW, NF_KEY_YY, NF_KEY_YYYY, NF_NUMBER_STANDARD, NF_NUMBER_SYSTEM, NF_SYMBOLTYPE_BLANK, NF_SYMBOLTYPE_CALENDAR, NF_SYMBOLTYPE_CURRENCY, NF_SYMBOLTYPE_CURREXT, NF_SYMBOLTYPE_DATESEP, NF_SYMBOLTYPE_DECSEP, NF_SYMBOLTYPE_DEL, NF_SYMBOLTYPE_DIGIT, NF_SYMBOLTYPE_EXP, NF_SYMBOLTYPE_FRACBLANK, NF_SYMBOLTYPE_PERCENT, NF_SYMBOLTYPE_STAR, NF_SYMBOLTYPE_STRING, NF_SYMBOLTYPE_THSEP, NF_SYMBOLTYPE_TIME100SECSEP, NF_SYMBOLTYPE_TIMESEP, NF_TEXT, nPos, NUMBERFORMAT_OP_EQ, NUMBERFORMAT_OP_GE, NUMBERFORMAT_OP_GT, NUMBERFORMAT_OP_LE, NUMBERFORMAT_OP_LT, NUMBERFORMAT_OP_NE, NUMBERFORMAT_OP_NO, SvtSaveOptions::ODFSVER_012, SvtSaveOptions::ODFSVER_EXTENDED, comphelper::string::padToLength(), SvXMLEmbeddedTextEntryArr::push_back(), SAL_WARN, SAL_WARN_IF, u, WriteAMPMElement_Impl(), WriteBooleanElement_Impl(), WriteColorElement_Impl(), WriteCurrencyElement_Impl(), WriteDayElement_Impl(), WriteDayOfWeekElement_Impl(), WriteEraElement_Impl(), WriteFractionElement_Impl(), WriteHoursElement_Impl(), WriteMapElement_Impl(), WriteMinutesElement_Impl(), WriteMonthElement_Impl(), WriteNumberElement_Impl(), WriteQuarterElement_Impl(), WriteRepeatedElement_Impl(), WriteScientificElement_Impl(), WriteSecondsElement_Impl(), WriteTextContentElement_Impl(), WriteTextWithCurrency_Impl(), WriteWeekElement_Impl(), WriteYearElement_Impl(), xmloff::token::XML_AUTOMATIC_ORDER, xmloff::token::XML_BOOLEAN_STYLE, xmloff::token::XML_CURRENCY_STYLE, xmloff::token::XML_DATE_STYLE, xmloff::token::XML_FALSE, xmloff::token::XML_FORMAT_SOURCE, xmloff::token::XML_LANGUAGE, xmloff::token::XML_NAME, XML_NAMESPACE_LO_EXT, XML_NAMESPACE_NUMBER, XML_NAMESPACE_STYLE, xmloff::token::XML_NUMBER_STYLE, xmloff::token::XML_PERCENTAGE_STYLE, xmloff::token::XML_TEXT, xmloff::token::XML_TEXT_STYLE, xmloff::token::XML_TIME_STYLE, xmloff::token::XML_TITLE, xmloff::token::XML_TOKEN_INVALID, xmloff::token::XML_TRANSLITERATION_COUNTRY, xmloff::token::XML_TRANSLITERATION_FORMAT, xmloff::token::XML_TRANSLITERATION_LANGUAGE, xmloff::token::XML_TRANSLITERATION_SPELLOUT, xmloff::token::XML_TRANSLITERATION_STYLE, xmloff::token::XML_TRUE, xmloff::token::XML_TRUNCATE_ON_OVERFLOW, and xmloff::token::XML_VOLATILE.

Referenced by ExportFormat_Impl().

◆ FinishTextElement_Impl()

void SvXMLNumFmtExport::FinishTextElement_Impl ( bool  bUseExtensionNS = false)
private

◆ ForceSystemLanguage()

sal_uInt32 SvXMLNumFmtExport::ForceSystemLanguage ( sal_uInt32  nKey)

◆ GetStyleName()

OUString SvXMLNumFmtExport::GetStyleName ( sal_uInt32  nKey)

◆ GetWasUsed()

uno::Sequence< sal_Int32 > SvXMLNumFmtExport::GetWasUsed ( ) const

Definition at line 1986 of file xmlnumfe.cxx.

References m_pUsedList.

◆ SetUsed()

void SvXMLNumFmtExport::SetUsed ( sal_uInt32  nKey)

◆ SetWasUsed()

void SvXMLNumFmtExport::SetWasUsed ( const css::uno::Sequence< sal_Int32 > &  rWasUsed)

Definition at line 1993 of file xmlnumfe.cxx.

References m_pUsedList.

◆ WriteAMPMElement_Impl()

void SvXMLNumFmtExport::WriteAMPMElement_Impl ( )
private

◆ WriteBooleanElement_Impl()

void SvXMLNumFmtExport::WriteBooleanElement_Impl ( )
private

◆ WriteColorElement_Impl()

void SvXMLNumFmtExport::WriteColorElement_Impl ( const Color rColor)
private

◆ WriteCurrencyElement_Impl()

void SvXMLNumFmtExport::WriteCurrencyElement_Impl ( const OUString &  rString,
std::u16string_view  rExt 
)
private

◆ WriteDayElement_Impl()

void SvXMLNumFmtExport::WriteDayElement_Impl ( const OUString &  rCalendar,
bool  bLong 
)
private

◆ WriteDayOfWeekElement_Impl()

void SvXMLNumFmtExport::WriteDayOfWeekElement_Impl ( const OUString &  rCalendar,
bool  bLong 
)
private

◆ WriteEmbeddedEntries_Impl()

void SvXMLNumFmtExport::WriteEmbeddedEntries_Impl ( const SvXMLEmbeddedTextEntryArr rEmbeddedEntries)
private

◆ WriteEraElement_Impl()

void SvXMLNumFmtExport::WriteEraElement_Impl ( const OUString &  rCalendar,
bool  bLong 
)
private

◆ WriteFractionElement_Impl()

void SvXMLNumFmtExport::WriteFractionElement_Impl ( sal_Int32  nInteger,
sal_Int32  nBlankInteger,
bool  bGrouping,
const SvNumberformat rFormat,
sal_uInt16  nPart 
)
private

◆ WriteHoursElement_Impl()

void SvXMLNumFmtExport::WriteHoursElement_Impl ( bool  bLong)
private

◆ WriteIntegerElement_Impl()

void SvXMLNumFmtExport::WriteIntegerElement_Impl ( sal_Int32  nInteger,
sal_Int32  nBlankInteger,
bool  bGrouping 
)
private

◆ WriteMapElement_Impl()

void SvXMLNumFmtExport::WriteMapElement_Impl ( sal_Int32  nOp,
double  fLimit,
sal_Int32  nKey,
sal_Int32  nPart 
)
private

◆ WriteMinutesElement_Impl()

void SvXMLNumFmtExport::WriteMinutesElement_Impl ( bool  bLong)
private

◆ WriteMonthElement_Impl()

void SvXMLNumFmtExport::WriteMonthElement_Impl ( const OUString &  rCalendar,
bool  bLong,
bool  bText 
)
private

◆ WriteNumberElement_Impl()

void SvXMLNumFmtExport::WriteNumberElement_Impl ( sal_Int32  nDecimals,
sal_Int32  nMinDecimals,
sal_Int32  nInteger,
sal_Int32  nBlankInteger,
const OUString &  rDashStr,
bool  bGrouping,
sal_Int32  nTrailingThousands,
const SvXMLEmbeddedTextEntryArr rEmbeddedEntries 
)
private

◆ WriteQuarterElement_Impl()

void SvXMLNumFmtExport::WriteQuarterElement_Impl ( const OUString &  rCalendar,
bool  bLong 
)
private

◆ WriteRepeatedElement_Impl()

void SvXMLNumFmtExport::WriteRepeatedElement_Impl ( sal_Unicode  ch)
private

◆ WriteScientificElement_Impl()

void SvXMLNumFmtExport::WriteScientificElement_Impl ( sal_Int32  nDecimals,
sal_Int32  nMinDecimals,
sal_Int32  nInteger,
sal_Int32  nBlankInteger,
bool  bGrouping,
sal_Int32  nExp,
sal_Int32  nExpInterval,
bool  bExpSign,
const SvXMLEmbeddedTextEntryArr rEmbeddedEntries 
)
private

◆ WriteSecondsElement_Impl()

void SvXMLNumFmtExport::WriteSecondsElement_Impl ( bool  bLong,
sal_uInt16  nDecimals 
)
private

◆ WriteTextContentElement_Impl()

void SvXMLNumFmtExport::WriteTextContentElement_Impl ( )
private

◆ WriteTextWithCurrency_Impl()

bool SvXMLNumFmtExport::WriteTextWithCurrency_Impl ( const OUString &  rString,
const css::lang::Locale &  rLocale 
)
private

◆ WriteWeekElement_Impl()

void SvXMLNumFmtExport::WriteWeekElement_Impl ( const OUString &  rCalendar)
private

◆ WriteYearElement_Impl()

void SvXMLNumFmtExport::WriteYearElement_Impl ( const OUString &  rCalendar,
bool  bLong 
)
private

Member Data Documentation

◆ m_bHasText

bool SvXMLNumFmtExport::m_bHasText
private

Definition at line 54 of file xmlnumfe.hxx.

Referenced by AddToTextElement_Impl(), ExportPart_Impl(), and FinishTextElement_Impl().

◆ m_pFormatter

SvNumberFormatter* SvXMLNumFmtExport::m_pFormatter
private

◆ m_pLocaleData

std::unique_ptr<LocaleDataWrapper> SvXMLNumFmtExport::m_pLocaleData
private

Definition at line 56 of file xmlnumfe.hxx.

Referenced by ExportPart_Impl(), and SvXMLNumFmtExport().

◆ m_pUsedList

std::unique_ptr<SvXMLNumUsedList_Impl> SvXMLNumFmtExport::m_pUsedList
private

Definition at line 55 of file xmlnumfe.hxx.

Referenced by Export(), GetStyleName(), GetWasUsed(), SetUsed(), SetWasUsed(), and SvXMLNumFmtExport().

◆ m_rExport

SvXMLExport& SvXMLNumFmtExport::m_rExport
private

◆ m_sPrefix

OUString SvXMLNumFmtExport::m_sPrefix
private

Definition at line 51 of file xmlnumfe.hxx.

Referenced by ExportPart_Impl(), GetStyleName(), and WriteMapElement_Impl().

◆ m_sTextContent

OUStringBuffer SvXMLNumFmtExport::m_sTextContent
private

Definition at line 53 of file xmlnumfe.hxx.

Referenced by AddToTextElement_Impl(), ExportPart_Impl(), and FinishTextElement_Impl().


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