LibreOffice
LibreOffice 24.2 SDK API Reference
Public Member Functions | List of all members
XLinguServiceManager Interface Referencepublished

the basic interface to be used to access linguistic functionality. More...

import"XLinguServiceManager.idl";

Inheritance diagram for XLinguServiceManager:
XInterface XLinguServiceManager2 LinguServiceManager

Public Member Functions

com::sun::star::linguistic2::XSpellChecker getSpellChecker ()
 
com::sun::star::linguistic2::XHyphenator getHyphenator ()
 
com::sun::star::linguistic2::XThesaurus getThesaurus ()
 
boolean addLinguServiceManagerListener ([in] com::sun::star::lang::XEventListener xListener)
 adds a listener to the list of event listeners. More...
 
boolean removeLinguServiceManagerListener ([in] com::sun::star::lang::XEventListener xListener)
 removes a listener from the list of event listeners. More...
 
sequence< string > getAvailableServices ([in] string aServiceName, [in] com::sun::star::lang::Locale aLocale)
 
void setConfiguredServices ([in] string aServiceName, [in] com::sun::star::lang::Locale aLocale, [in] sequence< string > aServiceImplNames)
 sets the list of service implementations to be used for a given service and language. More...
 
sequence< string > getConfiguredServices ([in] string aServiceName, [in] com::sun::star::lang::Locale aLocale)
 queries the list of service implementations to be used for a given service and language. More...
 
- Public Member Functions inherited from XInterface
any queryInterface ([in] type aType)
 queries for a new interface to an existing UNO object. More...
 
void acquire ()
 increases the reference counter by one. More...
 
void release ()
 decreases the reference counter by one. More...
 

Detailed Description

the basic interface to be used to access linguistic functionality.

This interface is used to access spell checker, hyphenator, and thesaurus functionality. Additionally, it can query what implementations of those services are available (for specific languages or in general). It can select and query which of those implementations should be used for a specific language.

For spell checking and thesaurus, the order in the list defines the order of creation/usage of those services. That is, if the first spell checker implementation does not recognize the given word as correct, the second service implementation for that language is created and gets queried. If that one fails, the third one gets created and queried and so on. This chain stops if an implementation reports the word as correct or the end of the list is reached, in which case the word is reported as incorrect.

For the thesaurus, the behavior is the same when no meaning was found.

See also
com::sun::star::linguistic2::SpellChecker
com::sun::star::linguistic2::Hyphenator
com::sun::star::linguistic2::Thesaurus

Member Function Documentation

◆ addLinguServiceManagerListener()

boolean addLinguServiceManagerListener ( [in] com::sun::star::lang::XEventListener  xListener)

adds a listener to the list of event listeners.

The listeners may support one or both of com::sun::star::linguistic2::XDictionaryEventListener and com::sun::star::linguistic2::XLinguServiceEventListener interfaces.

Returns
TRUE if the listener was successfully added, FALSE otherwise.
Parameters
xListenerthe listener to be added.

◆ getAvailableServices()

sequence< string > getAvailableServices ( [in] string  aServiceName,
[in] com::sun::star::lang::Locale  aLocale 
)
Returns
the list of implementation names of the available services.
Parameters
aServiceNamethe name of the service requesting the list of available implementations.
aLocalethe language used to query the list of available implementations.

◆ getConfiguredServices()

sequence< string > getConfiguredServices ( [in] string  aServiceName,
[in] com::sun::star::lang::Locale  aLocale 
)

queries the list of service implementations to be used for a given service and language.

Returns
the list of implementation names of the services to be used.
Parameters
aServiceNamethe name of the service to get queried.
aLocalethe language to get queried.

◆ getHyphenator()

Returns
the com::sun::star::linguistic2::XHyphenator interface to be used for hyphenation.

◆ getSpellChecker()

Returns
the com::sun::star::linguistic2::XSpellChecker interface to be used for spell checking.

◆ getThesaurus()

Returns
the com::sun::star::linguistic2::XThesaurus interface to be used for thesaurus functionality.

◆ removeLinguServiceManagerListener()

boolean removeLinguServiceManagerListener ( [in] com::sun::star::lang::XEventListener  xListener)

removes a listener from the list of event listeners.

Returns
TRUE if the listener was successfully removed, FALSE otherwise.
Parameters
xListenerthe listener to be removed.

◆ setConfiguredServices()

void setConfiguredServices ( [in] string  aServiceName,
[in] com::sun::star::lang::Locale  aLocale,
[in] sequence< string >  aServiceImplNames 
)

sets the list of service implementations to be used for a given service and language.

Parameters
aServiceNamethe name of the service to set the list of implementations to be used.
aLocalethe language to set the list.
aServiceImplNamesthe name of the service to set the list.

The documentation for this interface was generated from the following file: