C Configuration Space and Tuning Library (CCS)
Loading...
Searching...
No Matches
Functions
features.h File Reference

A features is a binding (see binding.h) over a feature space (see feature_space.h). More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

ccs_result_t ccs_create_features (ccs_feature_space_t feature_space, size_t num_values, ccs_datum_t *values, ccs_features_t *features_ret)
 Create a new instance of a features on a given feature space.
 
ccs_result_t ccs_features_get_feature_space (ccs_features_t features, ccs_feature_space_t *feature_space_ret)
 Get the associated feature space.
 

Detailed Description

A features is a binding (see binding.h) over a feature space (see feature_space.h).

Function Documentation

◆ ccs_create_features()

ccs_result_t ccs_create_features ( ccs_feature_space_t  feature_space,
size_t  num_values,
ccs_datum_t values,
ccs_features_t features_ret 
)
extern

Create a new instance of a features on a given feature space.

If no values are provided the values will be initialized to CCS_DATA_TYPE_NONE.

Parameters
[in]feature_space
[in]num_valuesthe number of provided values to initialize the features instance
[in]valuesan optional array of values to initialize the features
[out]features_reta pointer to the variable that will hold the newly created features
Returns
CCS_RESULT_SUCCESS on success
CCS_RESULT_ERROR_INVALID_OBJECT if features is not a valid CCS feature space
CCS_RESULT_ERROR_INVALID_VALUE if features_ret is NULL; or if values is NULL and num_values is greater than 0; or if the number of values provided is not equal to the number of parameters in the feature space
CCS_RESULT_ERROR_OUT_OF_MEMORY if there was a lack of memory to allocate the new features
Remarks
This function is thread-safe

◆ ccs_features_get_feature_space()

ccs_result_t ccs_features_get_feature_space ( ccs_features_t  features,
ccs_feature_space_t feature_space_ret 
)
extern

Get the associated feature space.

Parameters
[in]features
[out]feature_space_reta pointer to the variable that will contain the feature space
Returns
CCS_RESULT_SUCCESS on success
CCS_RESULT_ERROR_INVALID_OBJECT if features is not a valid CCS features
CCS_RESULT_ERROR_INVALID_VALUE if feature_space_ret is NULL
Remarks
This function is thread-safe