LibreOffice: XIdlClass Interface Reference

LibreOffice LibreOffice 26.8 SDK API Reference

Loading...
Searching...
No Matches
XIdlClass Interface Referencepublished

Provides information reflecting a UNO type. More...

`import "XIdlClass.idl";`

Inheritance diagram for XIdlClass:

## Public Member Functions
sequence< XIdlClass > | getClasses ()
| Deprecated.
XIdlClass | getClass ([in] string aName)
| Deprecated.
boolean | equals ([in] XIdlClass Type)
| Tests whether two reflecting objects reflect the same type.
boolean | isAssignableFrom ([in] XIdlClass xType)
| Tests whether values of this reflected type are assignable from values of a second one (`xType`).
com::sun::star::uno::TypeClass | getTypeClass ()
| Returns the com::sun::star::uno::TypeClass of the reflected type.
string | getName ()
| Returns the fully-qualified name of the reflected type.
com::sun::star::uno::Uik | getUik ()
| Deprecated.
sequence< XIdlClass > | getSuperclasses ()
| If the reflected type is an interface, then the returned sequence of XIdlClass reflect the base interfaces.
sequence< XIdlClass > | getInterfaces ()
| Deprecated.
XIdlClass | getComponentType ()
| If the reflected type is an array or sequence, then this method returns a XIdlClass interface reflecting the element.
XIdlField | getField ([in] string aName)
| If the reflected type is an interface, struct or union, then you get a XIdlField interface reflecting the demanded field (/interface attribute) by name.
sequence< XIdlField > | getFields ()
| If the reflected type is an interface, struct or union, then you get a sequence of XIdlField interfaces reflecting all fields (/interface attributes).
XIdlMethod | getMethod ([in] string aName)
| If the reflected type is an interface, then you get a XIdlMethod interface reflecting the demanded method by name.
sequence< XIdlMethod > | getMethods ()
| If the reflected type is an interface, then you get a sequence of XIdlMethod interfaces reflecting all methods of the interface.
XIdlArray | getArray ()
| If the reflected type is an array, then you get a XIdlArray interface to modify instances of the array type.
void | createObject ([out] any obj)
| This method creates instances of the reflected type.
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

Provides information reflecting a UNO type.

## Member Function Documentation

## ◆ createObject()

void createObject | ( | [out] any | obj | ) |

This method creates instances of the reflected type.

Attention
  Instances of type `any` can not be passed using an `any`, because anys cannot be nested. So if the reflected type is an `any`, then the returned value is empty.

Parameters

  obj | pure out parameter to pass the created instance

## ◆ equals()

boolean equals | ( | [in] XIdlClass | Type | ) |

Tests whether two reflecting objects reflect the same type.

Returns
  true, if the objects reflect the same type, false otherwise.

## ◆ getArray()

XIdlArray getArray | ( |  | ) |

If the reflected type is an array, then you get a XIdlArray interface to modify instances of the array type.

If the reflected type is not an array, then a null-reference is returned.

Returns
  interface to modify array instances (or null-reference)

## ◆ getClass()

XIdlClass getClass | ( | [in] string | aName | ) |

Deprecated.

Do not call.

Deprecated

## ◆ getClasses()

sequence< XIdlClass > getClasses | ( |  | ) |

Deprecated.

Do not call.

Deprecated

## ◆ getComponentType()

XIdlClass getComponentType | ( |  | ) |

If the reflected type is an array or sequence, then this method returns a XIdlClass interface reflecting the element.

Returns
  reflection interface of the element type of an array or sequence type (null-reference otherwise).

## ◆ getField()

XIdlField getField | ( | [in] string | aName | ) |

If the reflected type is an interface, struct or union, then you get a XIdlField interface reflecting the demanded field (/interface attribute) by name.

If the reflected type is not an interface, struct or union or the interface, struct or union does not have a field (/interface attribute) with the demanded name, then a null-reference is returned.

Parameters

  aName | name of the demanded field reflection

Returns
  demanded field (/interface attribute) reflection (or null-reference)

## ◆ getFields()

sequence< XIdlField > getFields | ( |  | ) |

If the reflected type is an interface, struct or union, then you get a sequence of XIdlField interfaces reflecting all fields (/interface attributes).

This also includes all inherited fields (/interface attributes) of the interface, struct of union.
If the reflected type is not an interface, struct or union or the interface, struct or union does not have any field (/interface attribute), then an empty sequence is returned.

Returns
  all field (/interface attribute) reflections (or empty sequence)

## ◆ getInterfaces()

sequence< XIdlClass > getInterfaces | ( |  | ) |

Deprecated.

Do not call.

Deprecated

## ◆ getMethod()

XIdlMethod getMethod | ( | [in] string | aName | ) |

If the reflected type is an interface, then you get a XIdlMethod interface reflecting the demanded method by name.

If the reflected type is not an interface or the interface does not have a method with the demanded name (including inherited methods), then a null-reference is returned.

Parameters

  aName | name of demanded method reflection

Returns
  demanded method reflection (or null-reference)

## ◆ getMethods()

sequence< XIdlMethod > getMethods | ( |  | ) |

If the reflected type is an interface, then you get a sequence of XIdlMethod interfaces reflecting all methods of the interface.

This also includes the inherited methods of the interface.
If the reflected type is not an interface or the interface does not have any methods, then a null-reference is returned.

Returns
  all method reflections (or empty sequence)

## ◆ getName()

string getName | ( |  | ) |

Returns the fully-qualified name of the reflected type.

Returns
  the fully-qualified name of the type

## ◆ getSuperclasses()

sequence< XIdlClass > getSuperclasses | ( |  | ) |

If the reflected type is an interface, then the returned sequence of XIdlClass reflect the base interfaces.

If the reflected type is not an interface or an interface that is not derived from another, then an empty sequence is returned.

Returns
  all base interfaces of an interface type or an empty sequence.

## ◆ getTypeClass()

com::sun::star::uno::TypeClass getTypeClass | ( |  | ) |

Returns the com::sun::star::uno::TypeClass of the reflected type.

Returns
  type class of the reflected type.

## ◆ getUik()

com::sun::star::uno::Uik getUik | ( |  | ) |

Deprecated.

Do not call.

Deprecated

## ◆ isAssignableFrom()

boolean isAssignableFrom | ( | [in] XIdlClass | xType | ) |

Tests whether values of this reflected type are assignable from values of a second one (`xType`).

Parameters

  xType | another reflected type

Returns
  true, if values of this reflected type are assignable from values of `xType`.

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

- com/sun/star/reflection/XIdlClass.idl