1.2.1 (revision 3238)
Data Structures | Typedefs | Functions
OTF2_AttributeList.h File Reference

This layer enables dynamic appending of arbitrary attributes to any type of event record. More...

#include <stdint.h>
#include <stdbool.h>
#include <otf2/OTF2_ErrorCodes.h>
#include <otf2/OTF2_GeneralDefinitions.h>

Go to the source code of this file.

Data Structures

union  OTF2_AttributeValue
 Value container for an attributes. More...

Typedefs

typedef struct
OTF2_AttributeList_struct 
OTF2_AttributeList
 Attribute list handle.

Functions

OTF2_ErrorCode OTF2_AttributeList_AddAttribute (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_Type type, OTF2_AttributeValue attributeValue)
 Add an attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddAttributeRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_AttributeRef attributeRef)
 Add an OTF2_TYPE_ATTRIBUTE attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddCommRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_CommRef commRef)
 Add an OTF2_TYPE_COMM attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddDouble (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, double float64Value)
 Add an OTF2_TYPE_DOUBLE attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddFloat (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, float float32Value)
 Add an OTF2_TYPE_FLOAT attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddGroupRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_GroupRef groupRef)
 Add an OTF2_TYPE_GROUP attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddInt16 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int16_t int16Value)
 Add an OTF2_TYPE_INT16 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddInt32 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int32_t int32Value)
 Add an OTF2_TYPE_INT32 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddInt64 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int64_t int64Value)
 Add an OTF2_TYPE_INT64 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddInt8 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int8_t int8Value)
 Add an OTF2_TYPE_INT8 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddLocationRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_LocationRef locationRef)
 Add an OTF2_TYPE_LOCATION attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddMetricRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_MetricRef metricRef)
 Add an OTF2_TYPE_METRIC attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddParameterRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_ParameterRef parameterRef)
 Add an OTF2_TYPE_PARAMETER attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddRegionRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_RegionRef regionRef)
 Add an OTF2_TYPE_REGION attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddRmaWinRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_RmaWinRef rmaWinRef)
 Add an OTF2_TYPE_RMA_WIN attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddString (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_StringRef stringRef)
 Add an OTF2_STRING attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddStringRef (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_StringRef stringRef)
 Add an OTF2_TYPE_STRING attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddUint16 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint16_t uint16Value)
 Add an OTF2_TYPE_UINT16 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddUint32 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint32_t uint32Value)
 Add an OTF2_TYPE_UINT32 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddUint64 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint64_t uint64Value)
 Add an OTF2_TYPE_UINT64 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_AddUint8 (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint8_t uint8Value)
 Add an OTF2_TYPE_UINT8 attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_Delete (OTF2_AttributeList *attributeList)
 Delete an attribute list handle.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeByID (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_Type *type, OTF2_AttributeValue *attributeValue)
 Get an attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeByIndex (const OTF2_AttributeList *attributeList, uint32_t index, OTF2_AttributeRef *attribute, OTF2_Type *type, OTF2_AttributeValue *attributeValue)
 Get an attribute from an attribute list by attribute index.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_AttributeRef *attributeRef)
 Get an OTF2_TYPE_ATTRIBUTE attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetCommRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_CommRef *commRef)
 Get an OTF2_TYPE_COMM attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetDouble (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, double *float64Value)
 Get an OTF2_TYPE_DOUBLE attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetFloat (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, float *float32Value)
 Get an OTF2_TYPE_FLOAT attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetGroupRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_GroupRef *groupRef)
 Get an OTF2_TYPE_GROUP attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetInt16 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int16_t *int16Value)
 Get an OTF2_TYPE_INT16 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetInt32 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int32_t *int32Value)
 Get an OTF2_TYPE_INT32 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetInt64 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int64_t *int64Value)
 Get an OTF2_TYPE_INT64 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetInt8 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, int8_t *int8Value)
 Get an OTF2_TYPE_INT8 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetLocationRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_LocationRef *locationRef)
 Get an OTF2_TYPE_LOCATION attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetMetricRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_MetricRef *metricRef)
 Get an OTF2_TYPE_METRIC attribute from an attribute list by attribute ID.
uint32_t OTF2_AttributeList_GetNumberOfElements (const OTF2_AttributeList *attributeList)
 Get the number of entries in an attribute list.
OTF2_ErrorCode OTF2_AttributeList_GetParameterRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_ParameterRef *parameterRef)
 Get an OTF2_TYPE_PARAMETER attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetRegionRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_RegionRef *regionRef)
 Get an OTF2_TYPE_REGION attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetRmaWinRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_RmaWinRef *rmaWinRef)
 Get an OTF2_TYPE_RMA_WIN attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetString (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_StringRef *stringRef)
 Add an OTF2_STRING attribute to an attribute list.
OTF2_ErrorCode OTF2_AttributeList_GetStringRef (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, OTF2_StringRef *stringRef)
 Get an OTF2_TYPE_STRING attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetUint16 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint16_t *uint16Value)
 Get an OTF2_TYPE_UINT16 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetUint32 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint32_t *uint32Value)
 Get an OTF2_TYPE_UINT32 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetUint64 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint64_t *uint64Value)
 Get an OTF2_TYPE_UINT64 attribute from an attribute list by attribute ID.
OTF2_ErrorCode OTF2_AttributeList_GetUint8 (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute, uint8_t *uint8Value)
 Get an OTF2_TYPE_UINT8 attribute from an attribute list by attribute ID.
OTF2_AttributeListOTF2_AttributeList_New (void)
 Create a new attribute list handle.
OTF2_ErrorCode OTF2_AttributeList_PopAttribute (OTF2_AttributeList *attributeList, OTF2_AttributeRef *attribute, OTF2_Type *type, OTF2_AttributeValue *attributeValue)
 Get first attribute from an attribute list and remove it.
OTF2_ErrorCode OTF2_AttributeList_RemoveAllAttributes (OTF2_AttributeList *attributeList)
 Remove all attributes from an attribute list.
OTF2_ErrorCode OTF2_AttributeList_RemoveAttribute (OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute)
 Remove an attribute from an attribute list.
bool OTF2_AttributeList_TestAttributeByID (const OTF2_AttributeList *attributeList, OTF2_AttributeRef attribute)
 Test if an attribute is in the attribute list.

Detailed Description

This layer enables dynamic appending of arbitrary attributes to any type of event record.

Source Template:
template/OTF2_AttributeList.tmpl.h
Maintainer:
Michael Wagner <michael.wagner@zih.tu-dresden.de>
Authors:
Dominic Eschweiler <d.eschweiler@fz-juelich.de>, Michael Wagner <michael.wagner@zih.tu-dresden.de>

How to use the attribute list for writing

additional attributes to event records.

First create an attribute list handle.

To write your additional attribute to an event record add your attributes to an empty attribute list right before you call the routine to write the event.

  OTF2_AttributeValue attr_value;
  attr_value.uint32 = attribute_value;
  OTF2_AttributeList_AddAttribute( attribute_list, attribute_id, OTF2_UINT8, attr_value );
  ...

Then call the routine to write the event and pass the attribute list. The additional attributes are added to the event record and will be appended when reading the event later on. Please note: All attributes in the list will be added to event record. So make sure that there are only those attributes in the attribute list that you actually like to write. Please note: After writing the event record all attributes are removed from the attribute list. So the attribute list is empty again. If you want to write identical attributes to multiple events you have to add them each time new.

  OTF2_EvtWriter_WriteEnter( ..., attribute_list, ... );

Function Documentation

OTF2_ErrorCode OTF2_AttributeList_AddAttribute ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_Type  type,
OTF2_AttributeValue  attributeValue 
)

Add an attribute to an attribute list.

Adds an attribute to an attribute list. If the attribute already exists, it fails and returns an error.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
typeType of the attribute.
attributeValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddAttributeRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_AttributeRef  attributeRef 
)

Add an OTF2_TYPE_ATTRIBUTE attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
attributeRefReference to Attribute definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddCommRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_CommRef  commRef 
)

Add an OTF2_TYPE_COMM attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
commRefReference to Comm definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddDouble ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
double  float64Value 
)

Add an OTF2_TYPE_DOUBLE attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
float64ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddFloat ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
float  float32Value 
)

Add an OTF2_TYPE_FLOAT attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
float32ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddGroupRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_GroupRef  groupRef 
)

Add an OTF2_TYPE_GROUP attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
groupRefReference to Group definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddInt16 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int16_t  int16Value 
)

Add an OTF2_TYPE_INT16 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
int16ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddInt32 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int32_t  int32Value 
)

Add an OTF2_TYPE_INT32 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
int32ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddInt64 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int64_t  int64Value 
)

Add an OTF2_TYPE_INT64 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
int64ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddInt8 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int8_t  int8Value 
)

Add an OTF2_TYPE_INT8 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
int8ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddLocationRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_LocationRef  locationRef 
)

Add an OTF2_TYPE_LOCATION attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
locationRefReference to Location definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddMetricRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_MetricRef  metricRef 
)

Add an OTF2_TYPE_METRIC attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
metricRefReference to Metric definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddParameterRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_ParameterRef  parameterRef 
)

Add an OTF2_TYPE_PARAMETER attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
parameterRefReference to Parameter definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddRegionRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_RegionRef  regionRef 
)

Add an OTF2_TYPE_REGION attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
regionRefReference to Region definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddRmaWinRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_RmaWinRef  rmaWinRef 
)

Add an OTF2_TYPE_RMA_WIN attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
rmaWinRefReference to RmaWin definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddString ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_StringRef  stringRef 
)

Add an OTF2_STRING attribute to an attribute list.

Deprecated:
Use OTF2_AttributeList_AddStringRef() instead.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
stringRefReference to String definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddStringRef ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_StringRef  stringRef 
)

Add an OTF2_TYPE_STRING attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
stringRefReference to String definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddUint16 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint16_t  uint16Value 
)

Add an OTF2_TYPE_UINT16 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
uint16ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddUint32 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint32_t  uint32Value 
)

Add an OTF2_TYPE_UINT32 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
uint32ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddUint64 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint64_t  uint64Value 
)

Add an OTF2_TYPE_UINT64 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
uint64ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_AddUint8 ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint8_t  uint8Value 
)

Add an OTF2_TYPE_UINT8 attribute to an attribute list.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
uint8ValueValue of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_Delete ( OTF2_AttributeList attributeList)

Delete an attribute list handle.

Deletes an attribute list handle and releases all associated resources.

Parameters:
attributeListAttribute list handle.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeByID ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_Type type,
OTF2_AttributeValue attributeValue 
)

Get an attribute from an attribute list by attribute ID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]typeReturned type of the attribute.
[out]attributeValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeByIndex ( const OTF2_AttributeList attributeList,
uint32_t  index,
OTF2_AttributeRef attribute,
OTF2_Type type,
OTF2_AttributeValue attributeValue 
)

Get an attribute from an attribute list by attribute index.

Parameters:
attributeListAttribute list handle.
indexPosition of the attribute in the attribute list.
[out]attributeReturned attribute reference.
[out]typeReturned type of the attribute.
[out]attributeValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetAttributeRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_AttributeRef attributeRef 
)

Get an OTF2_TYPE_ATTRIBUTE attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]attributeRefReturned attribute value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetCommRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_CommRef commRef 
)

Get an OTF2_TYPE_COMM attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]commRefReturned comm value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetDouble ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
double *  float64Value 
)

Get an OTF2_TYPE_DOUBLE attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]float64ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetFloat ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
float *  float32Value 
)

Get an OTF2_TYPE_FLOAT attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]float32ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetGroupRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_GroupRef groupRef 
)

Get an OTF2_TYPE_GROUP attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]groupRefReturned group value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetInt16 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int16_t *  int16Value 
)

Get an OTF2_TYPE_INT16 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]int16ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetInt32 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int32_t *  int32Value 
)

Get an OTF2_TYPE_INT32 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]int32ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetInt64 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int64_t *  int64Value 
)

Get an OTF2_TYPE_INT64 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]int64ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetInt8 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
int8_t *  int8Value 
)

Get an OTF2_TYPE_INT8 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]int8ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetLocationRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_LocationRef locationRef 
)

Get an OTF2_TYPE_LOCATION attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]locationRefReturned location value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetMetricRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_MetricRef metricRef 
)

Get an OTF2_TYPE_METRIC attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]metricRefReturned metric value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
uint32_t OTF2_AttributeList_GetNumberOfElements ( const OTF2_AttributeList attributeList)

Get the number of entries in an attribute list.

Parameters:
attributeListAttribute list handle.
Returns:
Returns the number of elements in the list. Returns zero if the list does not exist.
OTF2_ErrorCode OTF2_AttributeList_GetParameterRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_ParameterRef parameterRef 
)

Get an OTF2_TYPE_PARAMETER attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]parameterRefReturned parameter value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetRegionRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_RegionRef regionRef 
)

Get an OTF2_TYPE_REGION attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]regionRefReturned region value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetRmaWinRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_RmaWinRef rmaWinRef 
)

Get an OTF2_TYPE_RMA_WIN attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]rmaWinRefReturned rmaWin value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetString ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_StringRef stringRef 
)

Add an OTF2_STRING attribute to an attribute list.

Deprecated:
Use OTF2_AttributeList_GetStringRef() instead.

Convenient function around OTF2_AttributeList_AddAttribute.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]stringRefReturned string value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetStringRef ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
OTF2_StringRef stringRef 
)

Get an OTF2_TYPE_STRING attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to attribute definition.
[out]stringRefReturned string value.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetUint16 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint16_t *  uint16Value 
)

Get an OTF2_TYPE_UINT16 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]uint16ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetUint32 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint32_t *  uint32Value 
)

Get an OTF2_TYPE_UINT32 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]uint32ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetUint64 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint64_t *  uint64Value 
)

Get an OTF2_TYPE_UINT64 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]uint64ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_GetUint8 ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute,
uint8_t *  uint8Value 
)

Get an OTF2_TYPE_UINT8 attribute from an attribute list by attribute ID.

Convenient function around OTF2_AttributeList_GetAttributeByID.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
[out]uint8ValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_AttributeList* OTF2_AttributeList_New ( void  )

Create a new attribute list handle.

Returns:
Returns a handle to the attribute list if successful, NULL otherwise.
OTF2_ErrorCode OTF2_AttributeList_PopAttribute ( OTF2_AttributeList attributeList,
OTF2_AttributeRef attribute,
OTF2_Type type,
OTF2_AttributeValue attributeValue 
)

Get first attribute from an attribute list and remove it.

Returns the first entry in the attribute list and removes it from the list.

Parameters:
attributeListAttribute list handle.
[out]attributeReturned attribute reference.
[out]typeReturned type of the attribute.
[out]attributeValueReturned value of the attribute.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_RemoveAllAttributes ( OTF2_AttributeList attributeList)

Remove all attributes from an attribute list.

Parameters:
attributeListAttribute list handle.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
OTF2_ErrorCode OTF2_AttributeList_RemoveAttribute ( OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute 
)

Remove an attribute from an attribute list.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
Returns:
OTF2_SUCCESS if successful, an error code if an error occurs.
bool OTF2_AttributeList_TestAttributeByID ( const OTF2_AttributeList attributeList,
OTF2_AttributeRef  attribute 
)

Test if an attribute is in the attribute list.

Parameters:
attributeListAttribute list handle.
attributeReference to Attribute definition.
Returns:
True if the id is in the list, else false.