LibreOffice: XAttributes Interface Reference

LibreOffice LibreOffice 7.3 SDK API Reference

Public Member Functions | List of all members
XAttributes Interface Reference

An element's attributes. More...

`import"XAttributes.idl";`

Inheritance diagram for XAttributes:

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

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