LibreOffice: XAtomServer Interface Reference

LibreOffice LibreOffice 7.6 SDK API Reference

Loading...
Searching...
No Matches
Public Member Functions | List of all members
XAtomServer Interface Referencepublished

an interface to map between strings and ids More...

`import <XAtomServer.idl;`

Inheritance diagram for XAtomServer:

## Public Member Functions
sequence< AtomDescription > | getClass ([in] long atomClass)
| returns a whole atom class
sequence< sequence< AtomDescription > > | getClasses ([in] sequence< long > atomClasses)
| returns multiple atom classes
sequence< string > | getAtomDescriptions ([in] sequence< AtomClassRequest > atoms)
| returns the strings for an arbitrary amount of atoms of multiple classes
sequence< AtomDescription > | getRecentAtoms ([in] long atomClass, [in] long atom)
| returns the atoms that have been registered to a class after an already known atom
long | getAtom ([in] long atomClass, [in] string description, [in] boolean create)
| registers or searches for a string
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

an interface to map between strings and ids

a note on atoms:
Atoms are abbreviations for strings. When a string gets registered, it is assigned a numeric id so that said string can always be referred to by this id. This way strings have to be transported only once over remote connections. Valid ids are (in this implementation) non zero, signed 32 bit values. An atom of 0 means that the string in question is not registered

Additionally there is the abstraction of atom class:
Atoms are grouped into classes, so that an id can be assigned to multiple strings, depending on the class context. The main advantage of this is that atoms in one class may be kept to small numbers, so that bandwidth can be reduced by sending the atoms only as 16 bit values. Note that it is up to the user in this case to handle overflows.

## Member Function Documentation

## ◆ getAtom()

long getAtom | ( | [in] long | atomClass,
|  | [in] string | description,
|  | [in] boolean | create )

registers or searches for a string

Parameters

  atomClass | the class of atoms in question
  description | the string in question
  create | if true a new atom will be created for an unknown string else the invalid atom (0) will be returned for an unknown string

Returns
  the atom for the string `description`

## ◆ getAtomDescriptions()

sequence< string > getAtomDescriptions | ( | [in] sequence< AtomClassRequest > | atoms | ) |

returns the strings for an arbitrary amount of atoms of multiple classes

Parameters

  atoms | describes which strings to return

Returns
  the strings for the requested atoms

## ◆ getClass()

sequence< AtomDescription > getClass | ( | [in] long | atomClass | ) |

returns a whole atom class

Parameters

  atomClass | which class to return

Returns
  the descriptions for all atoms of class `atomClass`

## ◆ getClasses()

sequence< sequence< AtomDescription > > getClasses | ( | [in] sequence< long > | atomClasses | ) |

returns multiple atom classes

Parameters

  atomClasses | which classes to return

Returns
  the descriptions for all atoms of the requested classes

## ◆ getRecentAtoms()

sequence< AtomDescription > getRecentAtoms | ( | [in] long | atomClass,
|  | [in] long | atom )

returns the atoms that have been registered to a class after an already known atom

Hint to implementor: using ascending atoms is the easiest way to decide, which atoms are recent.

Parameters

  atomClass | the class in question
  atom | the last known atom

Returns
  all atom description that have been added to class `atomClass` after `atom`

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

- com/sun/star/util/XAtomServer.idl