LibreOffice LibreOffice 25.8 SDK API Reference

Public Member Functions | List of all members
XSimpleRegistry Interface Referencepublished

allows access to a registry (a persistent data source). More...

`import"XSimpleRegistry.idl";`

Inheritance diagram for XSimpleRegistry:

## Public Member Functions
string | getURL ()
| returns the URL of the current data source of the registry. More...
void | open ([in] string rURL, [in] boolean bReadOnly, [in] boolean bCreate) raises ( com::sun::star::registry::InvalidRegistryException )
| connects the registry to a persistent data source represented by a URL. More...
boolean | isValid ()
| checks if the registry points to a valid data-source. More...
void | close () raises ( com::sun::star::registry::InvalidRegistryException )
| disconnects the registry from the data-source. More...
void | destroy () raises ( com::sun::star::registry::InvalidRegistryException )
| destroys the registry and the data source. More...
com::sun::star::registry::XRegistryKey | getRootKey () raises ( com::sun::star::registry::InvalidRegistryException )
boolean | isReadOnly () raises ( com::sun::star::registry::InvalidRegistryException )
| checks if the registry is readonly. More...
void | mergeKey ([in] string aKeyName, [in] string aUrl) raises ( com::sun::star::registry::InvalidRegistryException, com::sun::star::registry::MergeConflictException )
| merges a registry under the specified key. 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

allows access to a registry (a persistent data source).

The data is stored in a hierarchical key structure beginning with a root key. Each key can store a value and can have multiple subkeys.

See also
  XRegistryKey

## Member Function Documentation

## ◆ close()

void close | ( |  | ) |
raises | ( | com::sun::star::registry::InvalidRegistryException
| ) |  |

disconnects the registry from the data-source.

Exceptions

  InvalidRegistryException | if the registry is not open.

## ◆ destroy()

void destroy | ( |  | ) |
raises | ( | com::sun::star::registry::InvalidRegistryException
| ) |  |

destroys the registry and the data source.

Exceptions

  InvalidRegistryException | if the registry is not open.

## ◆ getRootKey()

com::sun::star::registry::XRegistryKey getRootKey | ( |  | ) |
raises | ( | com::sun::star::registry::InvalidRegistryException
| ) |  |

Returns
  the root key of the registry.

Exceptions

  InvalidRegistryException | if no registry is open

## ◆ getURL()

string getURL | ( |  | ) |

returns the URL of the current data source of the registry.

## ◆ isReadOnly()

boolean isReadOnly | ( |  | ) |
raises | ( | com::sun::star::registry::InvalidRegistryException
| ) |  |

checks if the registry is readonly.

Exceptions

  InvalidRegistryException | if the registry is not open.

## ◆ isValid()

boolean isValid | ( |  | ) |

checks if the registry points to a valid data-source.

## ◆ mergeKey()

void mergeKey | ( | [in] string | aKeyName,
|  | [in] string | aUrl
| ) |  |
raises | ( | com::sun::star::registry::InvalidRegistryException,
|  | com::sun::star::registry::MergeConflictException
| ) |  |

merges a registry under the specified key.

Deprecated:
  The merge functionality is deprecated and not implemented. Implementations will throw a com::sun::star::RuntimeException.

## ◆ open()

void open | ( | [in] string | rURL,
|  | [in] boolean | bReadOnly,
|  | [in] boolean | bCreate
| ) |  |
raises | ( | com::sun::star::registry::InvalidRegistryException
| ) |  |

connects the registry to a persistent data source represented by a URL.

If a local registry is already open, this function will close the currently open registry.

Parameters

  rURL | specifies the complete URL to access the data source.
  bReadOnly | specifies if the data source should be opened for read only.
  bCreate | specifies if the data source should be created if it does not already exist.

Exceptions

  InvalidRegistryException | if the registry does not exist.

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

- com/sun/star/registry/XSimpleRegistry.idl