LibreOffice: XLinguServiceManager Interface Reference

LibreOffice LibreOffice 24.2 SDK API Reference

Loading...
Searching...
No Matches
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:

## 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.
boolean | removeLinguServiceManagerListener ([in] com::sun::star::lang::XEventListener xListener)
| removes a listener from the list of event listeners.
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.
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.
Public Member Functions inherited from XInterface
any | queryInterface ([in] type aType)
| queries for a new interface to an existing UNO object.
void | acquire ()
| increases the reference counter by one.
void | release ()
| decreases the reference counter by one.

## 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

  xListener | the 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

  aServiceName | the name of the service requesting the list of available implementations.
  aLocale | the 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

  aServiceName | the name of the service to get queried.
  aLocale | the language to get queried.

## ◆ getHyphenator()

com::sun::star::linguistic2::XHyphenator getHyphenator | ( |  | ) |

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

## ◆ getSpellChecker()

com::sun::star::linguistic2::XSpellChecker getSpellChecker | ( |  | ) |

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

## ◆ getThesaurus()

com::sun::star::linguistic2::XThesaurus 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

  xListener | the 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

  aServiceName | the name of the service to set the list of implementations to be used.
  aLocale | the language to set the list.
  aServiceImplNames | the name of the service to set the list.

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

- com/sun/star/linguistic2/XLinguServiceManager.idl