LibreOffice
LibreOffice 24.2 SDK API Reference
Public Member Functions | List of all members
XIdlArray Interface Referencepublished

Reflects an IDL sequence and provides dynamic access to instances of that sequence. More...

import"XIdlArray.idl";

Inheritance diagram for XIdlArray:
XInterface

Public Member Functions

void realloc ([inout] any array, [in] long length) raises ( com::sun::star::lang::IllegalArgumentException )
 Reallocates the length of the sequence instance. More...
 
long getLen ([in] any array) raises ( com::sun::star::lang::IllegalArgumentException )
 Returns the length of the given sequence. More...
 
any get ([in] any aArray, [in] long nIndex) raises ( com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::ArrayIndexOutOfBoundsException )
 Returns element at given index. More...
 
void set ([inout] any aArray, [in] long nIndex, [in] any aNewValue) raises ( com::sun::star::lang::IllegalArgumentException, com::sun::star::lang::ArrayIndexOutOfBoundsException )
 Sets a new value at given index. 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

Reflects an IDL sequence and provides dynamic access to instances of that sequence.

This interface supports widening conversion when getting or setting elements.

Attention
Although the name of this interface denotes arrays, sequences are meant. Don't be obfuscated, arrays are not supported by UNO!

Member Function Documentation

◆ get()

any get ( [in] any  aArray,
[in] long  nIndex 
)
raises ( com::sun::star::lang::IllegalArgumentException,
com::sun::star::lang::ArrayIndexOutOfBoundsException
)

Returns element at given index.

Parameters
aArraysequence instance
nIndexindex
Returns
value
Exceptions
IllegalArgumentExceptionif the specified object is not a sequence or if the specified object is null
ArrayIndexOutOfBoundsExceptionif the specified index argument is negative, or if it is greater than or equal to the length of the specified sequence.

◆ getLen()

long getLen ( [in] any  array)
raises (com::sun::star::lang::IllegalArgumentException
)

Returns the length of the given sequence.

Parameters
arraysequence instance
Returns
length of sequence

◆ realloc()

void realloc ( [inout] any  array,
[in] long  length 
)
raises (com::sun::star::lang::IllegalArgumentException
)

Reallocates the length of the sequence instance.

Parameters
arraysequence instance
lengthnew length of sequence

◆ set()

void set ( [inout] any  aArray,
[in] long  nIndex,
[in] any  aNewValue 
)
raises ( com::sun::star::lang::IllegalArgumentException,
com::sun::star::lang::ArrayIndexOutOfBoundsException
)

Sets a new value at given index.

Parameters
aArraysequence instance
nIndexindex
aNewValuenew value to be set
Exceptions
IllegalArgumentExceptionif the specified object is not a sequence or if the specified object is null
ArrayIndexOutOfBoundsExceptionif the specified index argument is negative, or if it is greater than or equal to the length of the specified sequence.

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