Ruminate
Type introspection for C
 All Classes Files Functions Enumerations Enumerator Macros Pages
RAggregateType Struct Reference

An opaque struct representing a aggregate type. More...

Inheritance diagram for RAggregateType:
Inheritance graph

Public Member Functions

RAggregateTypeId r_aggregate_type_id (RAggregateType *type, GError **error)
 Get the aggregate type identifier of this aggregate type. More...
 
size_t r_aggregate_type_nmembers (RAggregateType *type, GError **error)
 Get the number of members in this aggregate type. More...
 
RAggregateMemberr_aggregate_type_member_at (RAggregateType *type, size_t index, GError **error)
 Get an aggregate's member at a specified index. More...
 
RAggregateMemberr_aggregate_type_member_by_name (RAggregateType *type, const char *name, GError **error)
 Get an aggregate's member by name. More...
 
- Public Member Functions inherited from RType
RTypeId r_type_id (RType *type, GError **error)
 Get the type identifier of this type. More...
 
RStringr_type_name (RType *type, GError **error)
 Get the name of this type. More...
 
RTyper_type_ref (RType *type)
 Increase the reference count of this type. More...
 
void r_type_unref (RType *type)
 Decrease the reference count of this. More...
 
RTyper_type_pointer (RType *type, GError **error)
 Get an RType representing a pointer to this type. More...
 

Detailed Description

An opaque struct representing a aggregate type.

This aggregate type can be safely cast to it's sub-type which can be determined by using r_aggregate_type_id()

Member Function Documentation

RAggregateTypeId r_aggregate_type_id ( RAggregateType type,
GError **  error 
)

Get the aggregate type identifier of this aggregate type.

The RAggregateTypeId of this RAggregateType represents the child type of this RAggregateType, and can be safely cast into that child type.

Returns
the child type of this aggregate type.
Parameters
[in]typethe aggregate type to retrieve the id of
[out]errorsee errors.h
RAggregateMember * r_aggregate_type_member_at ( RAggregateType type,
size_t  index,
GError **  error 
)

Get an aggregate's member at a specified index.

Returns
a RAggregateMember representing the member of this aggregate at index index.
Parameters
[in]typethe aggregate type to retrieve a member of
[in]indexthe index of the member
[out]errorsee errors.h
RAggregateMember * r_aggregate_type_member_by_name ( RAggregateType type,
const char *  name,
GError **  error 
)

Get an aggregate's member by name.

Returns
a RAggregateMember representing the member of this aggregate with name name.
Parameters
[in]typethe aggregate type to retrieve a member of
[in]namethe name of the aggregate member
[out]errorsee errors.h
size_t r_aggregate_type_nmembers ( RAggregateType type,
GError **  error 
)

Get the number of members in this aggregate type.

Returns
the number of members in this aggregate type.
Parameters
[in]typethe type to get the number of members of
[out]errorsee errors.h

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