Simple Virtual Machine
A simple but flexible virtual machine
|
This module contains API functions to handle SVM plugin values. More...
Functions | |
SVM_FUNCTION SVM_Value_Plugin | svm_value_plugin_new (const void *svm, const SVM_Value_PluginEntryPoint type, void *value) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and generic C pointer. More... | |
SVM_FUNCTION SVM_Value_Plugin | svm_value_plugin_new_null (const void *svm, const SVM_Value_PluginEntryPoint type) |
This function creates a plugin value the SVM can store in its memories without a value. More... | |
SVM_FUNCTION SVM_Value_Plugin | svm_value_plugin_new_const (const void *svm, const SVM_Value_PluginEntryPoint type, const SVM_Value_String value) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a string value. More... | |
SVM_FUNCTION SVM_Value_Plugin | svm_value_plugin_new_const__string (const void *svm, const SVM_Value_PluginEntryPoint type, const SVM_String value) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a string. More... | |
SVM_FUNCTION SVM_Value_Plugin | svm_value_plugin_new_const__raw (const void *svm, const SVM_Value_PluginEntryPoint type, const char *value) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a raw C string. More... | |
SVM_FUNCTION SVM_Boolean | svm_value_type_is_plugin (const void *svm, const SVM_Value value, const SVM_Value_PluginEntryPoint type) |
This function checks whether a value contains a plugin value of a given type. More... | |
SVM_FUNCTION SVM_Value_PluginEntryPoint | svm_value_plugin_get_type (const void *svm, const SVM_Value_Plugin plugin) |
This function extracts the plugin value type contained in a plugin value. More... | |
SVM_FUNCTION void * | svm_value_plugin_get_internal (const void *svm, const SVM_Value_Plugin plugin) |
This function extracts the plugin value contained in a plugin value. More... | |
SVM_FUNCTION void | svm_value_plugin_set (const void *svm, SVM_Value_Plugin value, const SVM_Value_Plugin plugin) |
This function replaces the plugin value by another plugin value. More... | |
SVM_FUNCTION void | svm_value_plugin_set_internal (const void *svm, SVM_Value_Plugin value, const SVM_Value_PluginEntryPoint type, void *internal_value) |
This function replaces the type and the value contained in a plugin value from specific values. More... | |
SVM_FUNCTION SVM_Value_Plugin_Comparison | svm_value_plugin_compare_convert (const void *svm, const SVM_Comparison_Result compare) |
This function transforms a SVM_Comparison_Result into a SVM_Value_Plugin_Comparison. More... | |
This module contains API functions to handle SVM plugin values.
SVM_FUNCTION SVM_Value_Plugin_Comparison svm_value_plugin_compare_convert | ( | const void * | svm, |
const SVM_Comparison_Result | compare | ||
) |
This function transforms a SVM_Comparison_Result into a SVM_Value_Plugin_Comparison.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | compare | The value to be transformed. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
SVM_FUNCTION void * svm_value_plugin_get_internal | ( | const void * | svm, |
const SVM_Value_Plugin | plugin | ||
) |
This function extracts the plugin value contained in a plugin value.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | plugin | The plugin value to extract from. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
FAILURE | interruption when the value parameter does not contain a plugin value. |
SVM_FUNCTION SVM_Value_PluginEntryPoint svm_value_plugin_get_type | ( | const void * | svm, |
const SVM_Value_Plugin | plugin | ||
) |
This function extracts the plugin value type contained in a plugin value.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | plugin | The plugin value to extract from. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
FAILURE | interruption when the value parameter does not contain a plugin value. |
SVM_FUNCTION SVM_Value_Plugin svm_value_plugin_new | ( | const void * | svm, |
const SVM_Value_PluginEntryPoint | type, | ||
void * | value | ||
) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and generic C pointer.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | type | The extended type name. |
[in] | value | The raw value pointer. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist. |
SVM_FUNCTION SVM_Value_Plugin svm_value_plugin_new_const | ( | const void * | svm, |
const SVM_Value_PluginEntryPoint | type, | ||
const SVM_Value_String | value | ||
) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a string value.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | type | The extended type name. |
[in] | value | The string representation of the value. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist or when not constant constructible. |
SVM_FUNCTION SVM_Value_Plugin svm_value_plugin_new_const__raw | ( | const void * | svm, |
const SVM_Value_PluginEntryPoint | type, | ||
const char * | value | ||
) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a raw C string.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | type | The extended type name. |
[in] | value | The string representation of the value. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist or when not constant constructible. |
SVM_FUNCTION SVM_Value_Plugin svm_value_plugin_new_const__string | ( | const void * | svm, |
const SVM_Value_PluginEntryPoint | type, | ||
const SVM_String | value | ||
) |
This function creates a plugin defined value the SVM can store in its memories from a plugin entry point and a string.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | type | The extended type name. |
[in] | value | The string representation of the value. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist or when not constant constructible. |
SVM_FUNCTION SVM_Value_Plugin svm_value_plugin_new_null | ( | const void * | svm, |
const SVM_Value_PluginEntryPoint | type | ||
) |
This function creates a plugin value the SVM can store in its memories without a value.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | type | The plugin type of the null value. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist. |
SVM_FUNCTION void svm_value_plugin_set | ( | const void * | svm, |
SVM_Value_Plugin | value, | ||
const SVM_Value_Plugin | plugin | ||
) |
This function replaces the plugin value by another plugin value.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in,out] | value | The plugin value to update. |
[in] | plugin | The plugin to use for update. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
FAILURE | interruption when the value parameter does not contain a plugin value. |
FAILURE | interruption when the value parameter can not be deleted. |
FAILURE | interruption when the plugin parameter does not contain a plugin value. |
FAILURE | interruption when the plugin parameter internal value can not be copied. |
FAILURE | interruption when the value and plugin parameters have different types. |
FAILURE | interruption when the value is a constant. |
SVM_FUNCTION void svm_value_plugin_set_internal | ( | const void * | svm, |
SVM_Value_Plugin | value, | ||
const SVM_Value_PluginEntryPoint | type, | ||
void * | internal_value | ||
) |
This function replaces the type and the value contained in a plugin value from specific values.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in,out] | value | The interruption value to update. |
[in] | type | The plugin value type. |
[in] | internal_value | The plugin raw value. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
FAILURE | interruption when the value parameter does not contain a plugin value. |
FAILURE | interruption when the value parameter can not be deleted. |
FAILURE | interruption when the type is different from the value one. |
FAILURE | interruption when the value is a constant. |
MEMORY | interruption when the type does not identify a plugin type. |
SVM_FUNCTION SVM_Boolean svm_value_type_is_plugin | ( | const void * | svm, |
const SVM_Value | value, | ||
const SVM_Value_PluginEntryPoint | type | ||
) |
This function checks whether a value contains a plugin value of a given type.
[in] | svm | The SVM pointer passed as first argument of the callback function. |
[in] | value | The value to be diagnosed. |
[in] | type | The plugin type. |
FAILURE | interruption when a parameter is incorrect. (Please refer to the main description page of this API.) |
MEMORY | interruption when the type does not exist. |