LibreOffice
LibreOffice 5.3 SDK C/C++ API Reference
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
com::sun::star::uno::Type Class Reference

C++ class representing an IDL meta type. More...

#include <Type.h>

Public Member Functions

 Type ()
 Default Constructor: Type is set to void. More...
 
 Type (TypeClass eTypeClass, const ::rtl::OUString &rTypeName)
 Constructor: Type is constructed by given name and type class. More...
 
 Type (TypeClass eTypeClass, const sal_Char *pTypeName)
 Constructor: Type is constructed by given name and type class. More...
 
 Type (typelib_TypeDescriptionReference *pType)
 Constructor: Type is (copy) constructed by given C type description reference. More...
 
 Type (typelib_TypeDescriptionReference *pType, UnoType_NoAcquire dummy)
 Constructor: Type is (copy) constructed by given C type description reference without acquiring it. More...
 
 Type (typelib_TypeDescriptionReference *pType, __sal_NoAcquire dummy)
 Constructor: Type is (copy) constructed by given C type description reference without acquiring it. More...
 
 Type (const Type &rType)
 Copy constructor: Type is copy constructed by given type. More...
 
 ~Type ()
 Destructor: Releases acquired C type description reference. More...
 
Typeoperator= (const Type &rType)
 Assignment operator: Acquires right side type and releases previously set type. More...
 
TypeClass getTypeClass () const
 Gets the type class of set type. More...
 
inline::rtl::OUString getTypeName () const
 Gets the name of the set type. More...
 
void getDescription (typelib_TypeDescription **ppDescr) const
 Obtains a full type description of set type. More...
 
typelib_TypeDescriptionReferencegetTypeLibType () const
 Gets the C typelib type description reference pointer. More...
 
bool isAssignableFrom (const Type &rType) const
 Tests if values of this reflected type can be assigned by values of given type. More...
 
bool equals (const Type &rType) const
 Compares two types. More...
 
bool operator== (const Type &rType) const
 Equality operator: Compares two types. More...
 
bool operator!= (const Type &rType) const
 Unequality operator: Compares two types. More...
 

Detailed Description

C++ class representing an IDL meta type.

This class is used to represent a type, i.e. a type name and its type class. Internally the type holds a C type description reference of the runtime. You can obtain a full type description of a type by calling member function getDescription().

See Also
typelib_TypeDescriptionReference

Constructor & Destructor Documentation

com::sun::star::uno::Type::Type ( )
inline

Default Constructor: Type is set to void.

com::sun::star::uno::Type::Type ( TypeClass  eTypeClass,
const ::rtl::OUString rTypeName 
)
inline

Constructor: Type is constructed by given name and type class.

Parameters
eTypeClasstype class of type
rTypeNamename of type
com::sun::star::uno::Type::Type ( TypeClass  eTypeClass,
const sal_Char pTypeName 
)
inline

Constructor: Type is constructed by given name and type class.

Parameters
eTypeClasstype class of type
pTypeNamename of type
com::sun::star::uno::Type::Type ( typelib_TypeDescriptionReference pType)
inline

Constructor: Type is (copy) constructed by given C type description reference.

Parameters
pTypeC type description reference
com::sun::star::uno::Type::Type ( typelib_TypeDescriptionReference pType,
UnoType_NoAcquire  dummy 
)
inline

Constructor: Type is (copy) constructed by given C type description reference without acquiring it.

Parameters
pTypeC type description reference
dummyUNO_TYPE_NO_ACQUIRE to force obvious distinction to other constructors
com::sun::star::uno::Type::Type ( typelib_TypeDescriptionReference pType,
__sal_NoAcquire  dummy 
)
inline

Constructor: Type is (copy) constructed by given C type description reference without acquiring it.

Parameters
pTypeC type description reference
dummySAL_NO_ACQUIRE to force obvious distinction to other constructors
com::sun::star::uno::Type::Type ( const Type rType)
inline

Copy constructor: Type is copy constructed by given type.

Parameters
rTypeanother type
com::sun::star::uno::Type::~Type ( )
inline

Destructor: Releases acquired C type description reference.

Member Function Documentation

bool com::sun::star::uno::Type::equals ( const Type rType) const
inline

Compares two types.

Parameters
rTypeanother type
Returns
true if both types refer the same type, false otherwise
void com::sun::star::uno::Type::getDescription ( typelib_TypeDescription **  ppDescr) const
inline

Obtains a full type description of set type.

Parameters
ppDescr[inout] type description
TypeClass com::sun::star::uno::Type::getTypeClass ( ) const
inline

Gets the type class of set type.

Returns
type class of set type
typelib_TypeDescriptionReference* com::sun::star::uno::Type::getTypeLibType ( ) const
inline

Gets the C typelib type description reference pointer.

Does not acquire the reference!

Returns
UNacquired type description reference
rtl::OUString com::sun::star::uno::Type::getTypeName ( ) const
inline

Gets the name of the set type.

Returns
name of the set type
bool com::sun::star::uno::Type::isAssignableFrom ( const Type rType) const
inline

Tests if values of this reflected type can be assigned by values of given type.

This includes widening conversion (e.g., long assignable from short), as long as there is no data loss.

Parameters
rTypeanother type
Returns
true if values of this type can be assigned from values of given type, false otherwise
bool com::sun::star::uno::Type::operator!= ( const Type rType) const
inline

Unequality operator: Compares two types.

Parameters
rTypeanother type
Returns
false if both types refer the same type, true otherwise
Type & com::sun::star::uno::Type::operator= ( const Type rType)
inline

Assignment operator: Acquires right side type and releases previously set type.

Parameters
rTypeanother type (right side)
Returns
this type
bool com::sun::star::uno::Type::operator== ( const Type rType) const
inline

Equality operator: Compares two types.

Parameters
rTypeanother type
Returns
true if both types refer the same type, false otherwise

The documentation for this class was generated from the following files: