LibreOffice: XAttributes Interface Reference

LibreOffice LibreOffice 7.5 SDK API Reference

Loading...
Searching...
No Matches
Public Member Functions | List of all members
XAttributes Interface Reference

An element's attributes. More...

Inheritance diagram for XAttributes:

## Public Member Functions
long | getLength ()
| Gets the number of attributes.
long | getIndexByQName ([in] string qName)
| Gets attribute index passing a QName.
long | getIndexByUidName ([in] long uid, [in] string localName)
| Gets attribute index passing a namespace uid and a local name.
string | getQNameByIndex ([in] long nIndex)
| Gets the QName of an attribute.
long | getUidByIndex ([in] long nIndex)
| Gets the namespace uid of an attribute.
string | getLocalNameByIndex ([in] long nIndex)
| Gets the local name of an attribute.
string | getValueByIndex ([in] long nIndex)
| Gets the value of an attribute.
string | getValueByUidName ([in] long uid, [in] string localName)
| For convenience: Gets the value of an attribute passing uid, local name.
string | getTypeByIndex ([in] long nIndex)
| Gets the type of an attribute, if possible.
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 element's attributes.

## Member Function Documentation

## ◆ getIndexByQName()

long getIndexByQName | ( | [in] string | qName | ) |

Gets attribute index passing a QName.

Parameters

  qName | QName

Returns
  attribute index or -1, if not found

## ◆ getIndexByUidName()

long getIndexByUidName | ( | [in] long | uid,
|  | [in] string | localName
| ) |  |

Gets attribute index passing a namespace uid and a local name.

Parameters

  uid | namespace uid
  localName | local name

Returns
  attribute index or -1, if not found

## ◆ getLength()

long getLength | ( |  | ) |

Gets the number of attributes.

Returns
  number of attributes

## ◆ getLocalNameByIndex()

string getLocalNameByIndex | ( | [in] long | nIndex | ) |

Gets the local name of an attribute.

Parameters

  nIndex | index

Returns
  local name of attribute or empty string, if invalid index

## ◆ getQNameByIndex()

string getQNameByIndex | ( | [in] long | nIndex | ) |

Gets the QName of an attribute.

Parameters

  nIndex | index

Returns
  QName of attribute or empty string, if invalid index

## ◆ getTypeByIndex()

string getTypeByIndex | ( | [in] long | nIndex | ) |

Gets the type of an attribute, if possible.

Parameters

  nIndex | index

Returns
  type of attribute (if possible, else empty string)

## ◆ getUidByIndex()

long getUidByIndex | ( | [in] long | nIndex | ) |

Gets the namespace uid of an attribute.

Parameters

  nIndex | index

Returns
  namespace uid of attribute or -1, if invalid index

## ◆ getValueByIndex()

string getValueByIndex | ( | [in] long | nIndex | ) |

Gets the value of an attribute.

Parameters

  nIndex | index

Returns
  value string or empty string, if invalid index

## ◆ getValueByUidName()

string getValueByUidName | ( | [in] long | uid,
|  | [in] string | localName
| ) |  |

For convenience: Gets the value of an attribute passing uid, local name.

Parameters

  uid | namespace uid
  localName | local name

Returns
  value string or empty string, if invalid uid/local name

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

- com/sun/star/xml/input/XAttributes.idl