LibreOffice Module linguistic (master) 1
|
#include <convdic.hxx>
Public Member Functions | |
ConvDic (OUString aName, LanguageType nLanguage, sal_Int16 nConversionType, bool bBiDirectional, const OUString &rMainURL) | |
virtual | ~ConvDic () override |
virtual OUString SAL_CALL | getName () override |
virtual css::lang::Locale SAL_CALL | getLocale () override |
virtual sal_Int16 SAL_CALL | getConversionType () override |
virtual void SAL_CALL | setActive (sal_Bool bActivate) override |
virtual sal_Bool SAL_CALL | isActive () override |
virtual void SAL_CALL | clear () override |
virtual css::uno::Sequence< OUString > SAL_CALL | getConversions (const OUString &aText, sal_Int32 nStartPos, sal_Int32 nLength, css::linguistic2::ConversionDirection eDirection, sal_Int32 nTextConversionOptions) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getConversionEntries (css::linguistic2::ConversionDirection eDirection) override |
virtual void SAL_CALL | addEntry (const OUString &aLeftText, const OUString &aRightText) override |
virtual void SAL_CALL | removeEntry (const OUString &aLeftText, const OUString &aRightText) override |
virtual sal_Int16 SAL_CALL | getMaxCharCount (css::linguistic2::ConversionDirection eDirection) override |
virtual void SAL_CALL | setPropertyType (const OUString &aLeftText, const OUString &aRightText, ::sal_Int16 nPropertyType) override |
virtual ::sal_Int16 SAL_CALL | getPropertyType (const OUString &aLeftText, const OUString &aRightText) override |
virtual void SAL_CALL | flush () override |
virtual void SAL_CALL | addFlushListener (const css::uno::Reference< css::util::XFlushListener > &l) override |
virtual void SAL_CALL | removeFlushListener (const css::uno::Reference< css::util::XFlushListener > &l) override |
virtual OUString SAL_CALL | getImplementationName () override |
virtual sal_Bool SAL_CALL | supportsService (const OUString &ServiceName) override |
virtual css::uno::Sequence< OUString > SAL_CALL | getSupportedServiceNames () override |
bool | HasEntry (const OUString &rLeftText, std::u16string_view rRightText) |
void | AddEntry (const OUString &rLeftText, const OUString &rRightText) |
void | RemoveEntry (const OUString &rLeftText, const OUString &rRightText) |
Protected Member Functions | |
ConvDic (const ConvDic &) | |
ConvDic & | operator= (const ConvDic &) |
void | Load () |
void | Save () |
Static Protected Member Functions | |
static ConvMap::iterator | GetEntry (ConvMap &rMap, const OUString &rFirstText, std::u16string_view rSecondText) |
Protected Attributes | |
::comphelper::OInterfaceContainerHelper3< css::util::XFlushListener > | aFlushListeners |
ConvMap | aFromLeft |
std::unique_ptr< ConvMap > | pFromRight |
std::unique_ptr< PropTypeMap > | pConvPropType |
OUString | aMainURL |
OUString | aName |
LanguageType | nLanguage |
sal_Int16 | nConversionType |
sal_Int16 | nMaxLeftCharCount |
sal_Int16 | nMaxRightCharCount |
bool | bMaxCharCountIsValid |
bool | bNeedEntries |
bool | bIsModified |
bool | bIsActive |
Friends | |
class | ConvDicXMLExport |
Definition at line 44 of file convdic.hxx.
|
protected |
ConvDic::ConvDic | ( | OUString | aName, |
LanguageType | nLanguage, | ||
sal_Int16 | nConversionType, | ||
bool | bBiDirectional, | ||
const OUString & | rMainURL | ||
) |
create physical representation of an empty dictionary that could be found by the dictionary-list implementation
Definition at line 145 of file convdic.cxx.
References aName, bNeedEntries, linguistic::IsReadOnly(), LANGUAGE_CHINESE_SIMPLIFIED, LANGUAGE_CHINESE_TRADITIONAL, pConvPropType, pFromRight, and Save().
|
overridevirtual |
Definition at line 186 of file convdic.cxx.
|
overridevirtual |
Reimplemented in HHConvDic.
Definition at line 426 of file convdic.cxx.
References AddEntry(), bNeedEntries, linguistic::GetLinguMutex(), HasEntry(), and Load().
Referenced by HHConvDic::addEntry().
void ConvDic::AddEntry | ( | const OUString & | rLeftText, |
const OUString & | rRightText | ||
) |
Definition at line 272 of file convdic.cxx.
References aFromLeft, bIsModified, bMaxCharCountIsValid, bNeedEntries, DBG_ASSERT, HasEntry(), Load(), nMaxLeftCharCount, nMaxRightCharCount, and pFromRight.
Referenced by addEntry().
|
overridevirtual |
Definition at line 549 of file convdic.cxx.
References comphelper::OInterfaceContainerHelper3< class ListenerT >::addInterface(), aFlushListeners, and linguistic::GetLinguMutex().
|
overridevirtual |
Definition at line 350 of file convdic.cxx.
References aFromLeft, bIsModified, bMaxCharCountIsValid, bNeedEntries, linguistic::GetLinguMutex(), nMaxLeftCharCount, nMaxRightCharCount, and pFromRight.
|
overridevirtual |
Definition at line 533 of file convdic.cxx.
References aFlushListeners, bIsModified, linguistic::GetLinguMutex(), comphelper::OInterfaceContainerHelper3< class ListenerT >::notifyEach(), and Save().
|
overridevirtual |
Definition at line 396 of file convdic.cxx.
References aFromLeft, bNeedEntries, comphelper::containerToSequence(), linguistic::GetLinguMutex(), Load(), and pFromRight.
|
overridevirtual |
Definition at line 364 of file convdic.cxx.
References aFromLeft, bNeedEntries, comphelper::containerToSequence(), linguistic::GetLinguMutex(), Load(), nCount, nLength, and pFromRight.
|
overridevirtual |
Definition at line 329 of file convdic.cxx.
References linguistic::GetLinguMutex(), and nConversionType.
|
staticprotected |
Definition at line 247 of file convdic.cxx.
Referenced by HasEntry(), and RemoveEntry().
|
overridevirtual |
Reimplemented in HHConvDic.
Definition at line 567 of file convdic.cxx.
|
overridevirtual |
Definition at line 322 of file convdic.cxx.
References LanguageTag::convertToLocale(), linguistic::GetLinguMutex(), Locale, and nLanguage.
|
overridevirtual |
Definition at line 452 of file convdic.cxx.
References aFromLeft, bMaxCharCountIsValid, bNeedEntries, DBG_ASSERT, linguistic::GetLinguMutex(), Load(), nMaxLeftCharCount, nMaxRightCharCount, and pFromRight.
|
overridevirtual |
Definition at line 315 of file convdic.cxx.
References aName, and linguistic::GetLinguMutex().
|
override |
Definition at line 512 of file convdic.cxx.
References HasEntry(), and pConvPropType.
|
overridevirtual |
Reimplemented in HHConvDic.
Definition at line 577 of file convdic.cxx.
References SN_CONV_DICTIONARY.
bool ConvDic::HasEntry | ( | const OUString & | rLeftText, |
std::u16string_view | rRightText | ||
) |
Definition at line 263 of file convdic.cxx.
References aFromLeft, bNeedEntries, GetEntry(), and Load().
Referenced by addEntry(), AddEntry(), getPropertyType(), removeEntry(), and setPropertyType().
|
overridevirtual |
Definition at line 343 of file convdic.cxx.
References bIsActive, and linguistic::GetLinguMutex().
|
protected |
! prevent function from being called recursively via HasEntry, AddEntry
Definition at line 191 of file convdic.cxx.
References aMainURL, bIsModified, bNeedEntries, DBG_ASSERT, and ReadThroughDic().
Referenced by addEntry(), AddEntry(), getConversionEntries(), getConversions(), getMaxCharCount(), HasEntry(), removeEntry(), and RemoveEntry().
|
overridevirtual |
Definition at line 439 of file convdic.cxx.
References bNeedEntries, linguistic::GetLinguMutex(), HasEntry(), Load(), and RemoveEntry().
void ConvDic::RemoveEntry | ( | const OUString & | rLeftText, |
const OUString & | rRightText | ||
) |
Definition at line 294 of file convdic.cxx.
References aFromLeft, bIsModified, bMaxCharCountIsValid, bNeedEntries, DBG_ASSERT, GetEntry(), Load(), and pFromRight.
Referenced by removeEntry().
|
overridevirtual |
Definition at line 558 of file convdic.cxx.
References aFlushListeners, linguistic::GetLinguMutex(), and comphelper::OInterfaceContainerHelper3< class ListenerT >::removeInterface().
|
protected |
Definition at line 203 of file convdic.cxx.
References aMainURL, bIsModified, bNeedEntries, ConvDicXMLExport, utl::UcbStreamHelper::CreateStream(), DBG_ASSERT, comphelper::getProcessComponentContext(), SAL_WARN, and xStream.
|
overridevirtual |
Definition at line 336 of file convdic.cxx.
References bIsActive, and linguistic::GetLinguMutex().
|
overridevirtual |
Definition at line 495 of file convdic.cxx.
References bIsModified, HasEntry(), and pConvPropType.
|
overridevirtual |
Reimplemented in HHConvDic.
Definition at line 572 of file convdic.cxx.
References cppu::supportsService().
|
friend |
Definition at line 53 of file convdic.hxx.
Referenced by Save().
|
protected |
Definition at line 57 of file convdic.hxx.
Referenced by addFlushListener(), flush(), and removeFlushListener().
|
protected |
Definition at line 59 of file convdic.hxx.
Referenced by AddEntry(), clear(), ConvDicXMLExport::ExportContent_(), getConversionEntries(), getConversions(), getMaxCharCount(), HasEntry(), and RemoveEntry().
|
protected |
Definition at line 64 of file convdic.hxx.
|
protected |
Definition at line 65 of file convdic.hxx.
Referenced by getName().
|
protected |
Definition at line 73 of file convdic.hxx.
Referenced by isActive(), and setActive().
|
protected |
Definition at line 72 of file convdic.hxx.
Referenced by AddEntry(), clear(), flush(), Load(), RemoveEntry(), Save(), and setPropertyType().
|
protected |
Definition at line 70 of file convdic.hxx.
Referenced by AddEntry(), clear(), getMaxCharCount(), and RemoveEntry().
|
protected |
Definition at line 71 of file convdic.hxx.
Referenced by addEntry(), AddEntry(), clear(), ConvDic(), getConversionEntries(), getConversions(), getMaxCharCount(), HasEntry(), Load(), removeEntry(), RemoveEntry(), and Save().
|
protected |
Definition at line 67 of file convdic.hxx.
Referenced by ConvDicXMLExport::exportDoc(), and getConversionType().
|
protected |
Definition at line 66 of file convdic.hxx.
Referenced by ConvDicXMLExport::exportDoc(), and getLocale().
|
protected |
Definition at line 68 of file convdic.hxx.
Referenced by AddEntry(), clear(), and getMaxCharCount().
|
protected |
Definition at line 69 of file convdic.hxx.
Referenced by AddEntry(), clear(), and getMaxCharCount().
|
protected |
Definition at line 62 of file convdic.hxx.
Referenced by ConvDic(), ConvDicXMLExport::ExportContent_(), getPropertyType(), and setPropertyType().
|
protected |
Definition at line 60 of file convdic.hxx.
Referenced by AddEntry(), clear(), ConvDic(), getConversionEntries(), getConversions(), getMaxCharCount(), and RemoveEntry().