UDK 3.2.7 C/C++ API Reference
|
You can use this helper class to map a XPropertySet-Interface to a XFast- or a XMultiPropertySet interface. More...
#include <propshlp.hxx>
Public Member Functions | |
OPropertyArrayHelper (::com::sun::star::beans::Property *pProps, sal_Int32 nElements, sal_Bool bSorted=sal_True) throw () | |
Create an object which supports the common property interfaces. | |
OPropertyArrayHelper (const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Property > &aProps, sal_Bool bSorted=sal_True) throw () | |
Create an object which supports the common property interfaces. | |
sal_Int32 | getCount () const throw () |
Return the number of properties. | |
virtual sal_Bool | fillPropertyMembersByHandle (::rtl::OUString *pPropName, sal_Int16 *pAttributes, sal_Int32 nHandle) |
Return the property members Name and Attribute from the handle nHandle. | |
virtual ::com::sun::star::uno::Sequence < ::com::sun::star::beans::Property > | getProperties (void) |
Return the sequence of properties. | |
virtual ::com::sun::star::beans::Property | getPropertyByName (const ::rtl::OUString &rPropertyName) throw (::com::sun::star::beans::UnknownPropertyException) |
Return the property with the name rPropertyName. | |
virtual sal_Bool | hasPropertyByName (const ::rtl::OUString &rPropertyName) |
Return true if the property with the name rPropertyName exist, otherwise false. | |
virtual sal_Int32 | getHandleByName (const ::rtl::OUString &rPropertyName) |
Return the handle of the property with the name rPropertyName. | |
virtual sal_Int32 | fillHandles (sal_Int32 *pHandles, const ::com::sun::star::uno::Sequence< ::rtl::OUString > &rPropNames) |
Fill the array with the handles of the properties. | |
Protected Attributes | |
void * | m_pReserved |
reserved for future use. |
You can use this helper class to map a XPropertySet-Interface to a XFast- or a XMultiPropertySet interface.
cppu::OPropertyArrayHelper::OPropertyArrayHelper | ( | ::com::sun::star::beans::Property * | pProps, |
sal_Int32 | nElements, | ||
sal_Bool | bSorted = sal_True |
||
) | throw () |
Create an object which supports the common property interfaces.
pProps | array of properties The array pProps should be sorted. |
nElements | is the number of properties in the pProps structure. |
bSorted | indicates that the elements are sorted. |
cppu::OPropertyArrayHelper::OPropertyArrayHelper | ( | const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Property > & | aProps, |
sal_Bool | bSorted = sal_True |
||
) | throw () |
Create an object which supports the common property interfaces.
aProps | sequence of properties which are supported by this helper. The sequence aProps should be sorted. |
bSorted | indicates that the elements are sorted. |
virtual sal_Int32 cppu::OPropertyArrayHelper::fillHandles | ( | sal_Int32 * | pHandles, |
const ::com::sun::star::uno::Sequence< ::rtl::OUString > & | rPropNames | ||
) | [virtual] |
Fill the array with the handles of the properties.
Implements cppu::IPropertyArrayHelper.
virtual sal_Bool cppu::OPropertyArrayHelper::fillPropertyMembersByHandle | ( | ::rtl::OUString * | pPropName, |
sal_Int16 * | pAttributes, | ||
sal_Int32 | nHandle | ||
) | [virtual] |
Return the property members Name and Attribute from the handle nHandle.
nHandle | the handle of a property. If the values of the handles are sorted in the same way as the names and the highest handle value is getCount() -1, than it is only an indexed acces to the property array. Otherwise it is a linear search through the array. |
pPropName | is an out parameter filled with property name of the property with the handle nHandle. May be NULL. |
pAttributes | is an out parameter filled with attributes of the property with the handle nHandle. May be NULL. |
Implements cppu::IPropertyArrayHelper.
sal_Int32 cppu::OPropertyArrayHelper::getCount | ( | ) | const throw () |
Return the number of properties.
virtual sal_Int32 cppu::OPropertyArrayHelper::getHandleByName | ( | const ::rtl::OUString & | rPropertyName | ) | [virtual] |
Return the handle of the property with the name rPropertyName.
If the property does not exist -1 is returned.
rPropertyName | the name of the property. |
Implements cppu::IPropertyArrayHelper.
virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::Property > cppu::OPropertyArrayHelper::getProperties | ( | void | ) | [virtual] |
Return the sequence of properties.
The sequence is sorted by name.
Implements cppu::IPropertyArrayHelper.
virtual ::com::sun::star::beans::Property cppu::OPropertyArrayHelper::getPropertyByName | ( | const ::rtl::OUString & | rPropertyName | ) | throw (::com::sun::star::beans::UnknownPropertyException) [virtual] |
Return the property with the name rPropertyName.
rPropertyName | the name of the property. |
UnknownPropertyException | thrown if the property name is unknown. |
Implements cppu::IPropertyArrayHelper.
virtual sal_Bool cppu::OPropertyArrayHelper::hasPropertyByName | ( | const ::rtl::OUString & | rPropertyName | ) | [virtual] |
Return true if the property with the name rPropertyName exist, otherwise false.
rPropertyName | the name of the property. |
Implements cppu::IPropertyArrayHelper.
void* cppu::OPropertyArrayHelper::m_pReserved [protected] |
reserved for future use.
do not use.