definitions.h File Reference

Definitions module header file. More...

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

Go to the source code of this file.

Macros

#define MCL_SIZE_MAX   ((mcl_size_t) - 1)
 
#define MCL_NULL   ((void *)0)
 
#define MCL_NULL_CHAR   '\0'
 
#define MCL_NULL_CHAR_SIZE   1
 
#define NONCE_SIZE   16
 
#define DEFAULT_META_TYPE_SIZE   6
 
#define DEFAULT_PAYLOAD_TYPE_SIZE   20
 
#define DEFAULT_QUALITY_CODE_SIZE   9
 
#define DEFAULT_DATE_SIZE   23
 
#define DEFAULT_TIMESTAMP_SIZE   25
 
#define DEFAULT_ID_SIZE   37
 
#define DEFAULT_VALUES_COUNT   5
 
#define DEFAULT_VALUE_SIZE   11
 
#define MAXIMUM_HOST_NAME_LENGTH   256
 
#define MAXIMUM_PROXY_USER_NAME_LENGTH   32
 
#define MAXIMUM_PROXY_PASSWORD_LENGTH   32
 
#define MAXIMUM_PROXY_DOMAIN_LENGTH   256
 
#define MAXIMUM_USER_AGENT_LENGTH   512
 
#define MIN_HTTP_PAYLOAD_SIZE   400
 
#define DEFAULT_HTTP_PAYLOAD_SIZE   16384
 
#define DEFAULT_HTTP_REQUEST_TIMEOUT   (300)
 
#define JWT_EXPIRATION_TIME   86400
 
#define MCL_FILE_EXCHANGE_ENABLED   1
 
#define MCL_ERROR_RETURN_POINTER(return_value, ...)
 
#define MCL_ERROR_RETURN(return_value, ...)
 
#define ASSERT(condition)
 
#define ASSERT_MESSAGE(condition, ...)
 
#define ASSERT_STATEMENT_MESSAGE(condition, statement, ...)
 
#define ASSERT_CODE(condition, return_code)
 
#define ASSERT_CODE_MESSAGE(condition, return_code, ...)
 
#define ASSERT_STATEMENT_CODE(condition, statement, return_code)
 
#define ASSERT_STATEMENT_CODE_MESSAGE(condition, statement, return_code, ...)
 
#define ASSERT_NOT_NULL(argument)
 
#define STRING_CONSTANT(s)   {s, sizeof(s)/sizeof(s[0]) - 1, MCL_STRING_NOT_COPY_NOT_DESTROY}
 

Detailed Description

Definitions module header file.


Date
Jul 28, 2016 General definitions are stored in this header file.

Definition in file definitions.h.

Macro Definition Documentation

#define ASSERT (   condition)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
DEBUG_LEAVE("retVal = <%p>", MCL_NULL); \
return MCL_NULL; \
}
#define MCL_NULL
Definition: definitions.h:24

Definition at line 74 of file definitions.h.

#define ASSERT_CODE (   condition,
  return_code 
)
#define ASSERT_CODE_MESSAGE (   condition,
  return_code,
  ... 
)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
MCL_ERROR_RETURN(return_code, __VA_ARGS__); \
}

Definition at line 105 of file definitions.h.

Referenced by _add_authentication_header_to_request(), _add_boundary(), _add_content_info(), _add_data_source_configuration_data_points(), _add_data_source_configuration_data_sources(), _add_event(), _add_event_list(), _add_item_meta_details(), _add_item_meta_payload(), _add_item_meta_payload_details(), _add_key_to_keys_array(), _add_schema_to_jwt(), _add_time_series_payload_values_array(), _add_time_series_value_sets(), _calculate_signature(), _create_self_issued_jwt_payload(), _decode_quantum(), _decode_with_table(), _encode_with_table(), _exchange_add_current_data_to_request(), _exchange_add_current_data_to_request_by_streaming(), _exchange_fill_http_request(), _exchange_finalize_http_request(), _exchange_initialize_http_request_headers(), _exchange_prepare_data(), _generate_random_boundary(), _generate_token(), _get_header_and_payload_encoded_base64_url(), _get_rsa_private_key(), _get_rsa_public_key(), _initialize(), _initialize_custom_data_meta_fields(), _initialize_meta(), _join_with_dot(), _process_registration_response_rsa_3072(), _process_registration_response_shared_secret(), _resize_payload_buffer_if_necessary(), _response_payload_callback(), _ssl_context_callback(), _store_add_data(), custom_data_initialize(), data_source_configuration_initialize(), file_initialize(), hmac_sha256(), http_client_initialize(), http_processor_exchange(), http_processor_get_access_token(), http_processor_initialize(), http_processor_register(), http_processor_stream(), http_processor_update_security_information(), http_request_add_header(), http_request_add_raw_data(), http_request_add_single(), http_request_add_tuple(), http_request_end_tuple_sub_section(), http_request_finalize(), http_request_initialize(), http_request_start_tuple(), http_request_start_tuple_sub_section(), http_response_get_header(), http_response_initialize(), json_from_event_payload(), json_from_item_meta(), json_from_time_series_payload(), json_util_add_bool(), json_util_add_double(), json_util_add_null(), json_util_add_object(), json_util_add_string(), json_util_add_uint(), json_util_duplicate(), json_util_get_array_item(), json_util_get_object_item(), json_util_get_string(), json_util_initialize(), json_util_parse(), json_util_parse_with_size(), json_util_start_array(), json_util_start_object(), json_util_to_string(), jwt_initialize(), list_add(), list_initialize(), list_remove(), mcl_communication_exchange(), mcl_communication_get_access_token(), mcl_communication_get_last_access_token(), mcl_communication_get_last_token_time(), mcl_communication_initialize(), mcl_communication_process(), mcl_configuration_initialize(), mcl_custom_data_set_payload(), mcl_data_source_configuration_add_data_point(), mcl_data_source_configuration_add_data_source(), mcl_data_source_configuration_get_id(), mcl_json_util_get_string(), mcl_random_generate_guid(), mcl_store_initialize(), mcl_store_new_custom_data(), mcl_store_new_data_source_configuration(), mcl_store_new_event(), mcl_store_new_file(), mcl_store_new_stream_data(), mcl_store_new_time_series(), mcl_time_series_add_value(), mcl_time_series_new_value_set(), random_generate_guid(), security_generate_rsa_key(), security_handler_initialize(), security_hash_sha256(), security_rsa_get_modulus_and_exponent(), security_rsa_sign(), storage_load_rsa_registration_information(), storage_load_shared_secret_registration_information(), stream_data_initialize(), string_array_add(), string_array_initialize(), string_array_set_increment(), string_convert_binary_to_hex(), string_initialize(), string_initialize_dynamic(), string_initialize_new(), string_initialize_static(), string_replace(), string_set(), string_split(), and time_series_initialize().

#define ASSERT_MESSAGE (   condition,
  ... 
)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
MCL_ERROR_RETURN_POINTER(MCL_NULL, __VA_ARGS__); \
}
#define MCL_NULL
Definition: definitions.h:24

Definition at line 82 of file definitions.h.

Referenced by list_next(), memory_allocate(), memory_allocate_with_zero(), memory_reallocate(), random_generate_array(), string_array_get(), and string_array_to_string().

#define ASSERT_NOT_NULL (   argument)
Value:
if(MCL_NULL == argument) \
{ \
MCL_ERROR_RETURN(MCL_TRIGGERED_WITH_NULL, "Null function argument (" #argument ")."); \
}
#define MCL_NULL
Definition: definitions.h:24
Received parameter is null.
Definition: mcl_common.h:142

Definition at line 129 of file definitions.h.

Referenced by file_initialize(), mcl_communication_destroy(), mcl_communication_exchange(), mcl_communication_get_access_token(), mcl_communication_get_last_access_token(), mcl_communication_get_last_token_time(), mcl_communication_initialize(), mcl_communication_is_initialized(), mcl_communication_is_onboarded(), mcl_communication_onboard(), mcl_communication_process(), mcl_communication_rotate_key(), mcl_communication_update_security_information(), mcl_configuration_destroy(), mcl_configuration_initialize(), mcl_custom_data_set_meta_details(), mcl_custom_data_set_payload(), mcl_data_source_configuration_add_data_point(), mcl_data_source_configuration_add_data_source(), mcl_data_source_configuration_get_id(), mcl_event_set_option(), mcl_json_util_add_bool(), mcl_json_util_add_double(), mcl_json_util_add_item_to_array(), mcl_json_util_add_null(), mcl_json_util_add_object(), mcl_json_util_add_string(), mcl_json_util_add_uint(), mcl_json_util_get_array_item(), mcl_json_util_get_array_size(), mcl_json_util_get_bool_value(), mcl_json_util_get_double_value(), mcl_json_util_get_number_value(), mcl_json_util_get_object_item(), mcl_json_util_get_string(), mcl_json_util_has_child(), mcl_json_util_initialize(), mcl_json_util_parse(), mcl_json_util_start_array(), mcl_json_util_start_object(), mcl_json_util_to_string(), mcl_list_add(), mcl_list_exist(), mcl_list_initialize(), mcl_list_next(), mcl_list_remove(), mcl_list_remove_with_content(), mcl_random_generate_guid(), mcl_store_destroy(), mcl_store_initialize(), mcl_store_new_custom_data(), mcl_store_new_data_source_configuration(), mcl_store_new_event(), mcl_store_new_file(), mcl_store_new_stream_data(), mcl_store_new_time_series(), mcl_stream_data_set_meta_details(), mcl_time_series_add_value(), and mcl_time_series_new_value_set().

#define ASSERT_STATEMENT_CODE (   condition,
  statement,
  return_code 
)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
(statement); \
DEBUG_LEAVE("retVal = <%d>", (return_code)); \
return (return_code); \
}

Definition at line 112 of file definitions.h.

Referenced by _add_time_series_value_set(), and _generate_correlation_id_string().

#define ASSERT_STATEMENT_CODE_MESSAGE (   condition,
  statement,
  return_code,
  ... 
)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
(statement); \
MCL_ERROR_RETURN(return_code, __VA_ARGS__); \
}

Definition at line 121 of file definitions.h.

Referenced by _add_item_meta_payload_details(), _add_time_series_payload_values_array(), _add_time_series_payload_values_objects(), _concatenate_host_and_endpoint(), _create_self_issued_jwt_payload(), _decode_with_table(), _get_rsa_private_key(), _get_rsa_public_key(), _process_registration_response_rsa_3072(), _store_add_data(), custom_data_initialize(), event_list_initialize(), file_initialize(), hmac_sha256(), http_client_send(), http_processor_get_access_token(), http_processor_initialize(), http_processor_register(), http_request_add_header(), http_request_add_tuple(), http_request_initialize(), json_from_event_payload(), json_from_item_meta(), json_from_time_series_payload(), json_util_duplicate(), json_util_get_array_item(), json_util_initialize(), json_util_parse(), json_util_parse_with_size(), jwt_initialize(), mcl_communication_get_last_access_token(), mcl_communication_get_last_token_time(), mcl_communication_initialize(), mcl_store_initialize(), mcl_store_new_custom_data(), mcl_store_new_data_source_configuration(), mcl_store_new_event(), mcl_store_new_file(), mcl_store_new_stream_data(), mcl_store_new_time_series(), mcl_time_series_add_value(), mcl_time_series_new_value_set(), random_generate_guid(), security_generate_rsa_key(), security_rsa_get_modulus_and_exponent(), security_rsa_sign(), storage_load_rsa_registration_information(), storage_load_shared_secret_registration_information(), stream_data_initialize(), string_concatenate(), string_concatenate_cstr(), string_replace(), time_series_initialize(), and time_util_convert_to_iso_8601_format().

#define ASSERT_STATEMENT_MESSAGE (   condition,
  statement,
  ... 
)
Value:
if(!(condition)) \
{ \
MCL_ERROR_STRING("Assertion failed for condition = <" #condition ">."); \
(statement); \
MCL_ERROR_RETURN_POINTER(MCL_NULL, __VA_ARGS__); \
}
#define MCL_NULL
Definition: definitions.h:24

Definition at line 89 of file definitions.h.

Referenced by random_generate_array().

#define DEFAULT_DATE_SIZE   23

Definition at line 36 of file definitions.h.

#define DEFAULT_HTTP_PAYLOAD_SIZE   16384

Definition at line 54 of file definitions.h.

Referenced by mcl_communication_initialize(), and mcl_configuration_initialize().

#define DEFAULT_HTTP_REQUEST_TIMEOUT   (300)

Definition at line 57 of file definitions.h.

Referenced by mcl_configuration_initialize().

#define DEFAULT_ID_SIZE   37

Definition at line 38 of file definitions.h.

#define DEFAULT_META_TYPE_SIZE   6

Definition at line 33 of file definitions.h.

#define DEFAULT_PAYLOAD_TYPE_SIZE   20

Definition at line 34 of file definitions.h.

#define DEFAULT_QUALITY_CODE_SIZE   9

Definition at line 35 of file definitions.h.

#define DEFAULT_TIMESTAMP_SIZE   25

Definition at line 37 of file definitions.h.

#define DEFAULT_VALUE_SIZE   11

Definition at line 42 of file definitions.h.

#define DEFAULT_VALUES_COUNT   5

Definition at line 39 of file definitions.h.

#define JWT_EXPIRATION_TIME   86400

Definition at line 60 of file definitions.h.

Referenced by _create_self_issued_jwt_payload().

#define MAXIMUM_HOST_NAME_LENGTH   256

Definition at line 44 of file definitions.h.

Referenced by mcl_communication_initialize().

#define MAXIMUM_PROXY_DOMAIN_LENGTH   256

Definition at line 47 of file definitions.h.

Referenced by mcl_communication_initialize().

#define MAXIMUM_PROXY_PASSWORD_LENGTH   32

Definition at line 46 of file definitions.h.

Referenced by mcl_communication_initialize().

#define MAXIMUM_PROXY_USER_NAME_LENGTH   32

Definition at line 45 of file definitions.h.

Referenced by mcl_communication_initialize().

#define MAXIMUM_USER_AGENT_LENGTH   512

Definition at line 48 of file definitions.h.

Referenced by mcl_communication_initialize().

#define MCL_ERROR_RETURN_POINTER (   return_value,
  ... 
)
Value:
MCL_ERROR(__VA_ARGS__); \
DEBUG_LEAVE("retVal = <%p>", (return_value)); \
return (return_value);
#define MCL_ERROR(...)
Definition: log_util.h:97

Definition at line 64 of file definitions.h.

Referenced by string_array_to_string().

#define MCL_FILE_EXCHANGE_ENABLED   1

Definition at line 62 of file definitions.h.

#define MCL_NULL   ((void *)0)

Definition at line 24 of file definitions.h.

Referenced by _add_authentication_header_to_request(), _add_boundary(), _add_content_info(), _add_data_source_configuration_data_points(), _add_data_source_configuration_data_sources(), _add_event(), _add_event_list(), _add_item_meta_details(), _add_item_meta_payload(), _add_item_meta_payload_details(), _add_schema_to_jwt(), _add_string_field_to_object(), _add_time_series_payload_values_array(), _add_time_series_payload_values_objects(), _add_time_series_value_set(), _add_time_series_value_sets(), _base64_encode_big_number(), _calculate_signature(), _check_file_path(), _compose_access_token_request_payload(), _compose_rsa_key_rotation_json(), _compose_rsa_onboarding_json(), _concatenate_host_and_endpoint(), _create_self_issued_jwt_payload(), _decode_with_table(), _encode_with_table(), _exchange_add_current_data_to_request(), _exchange_add_current_data_to_request_by_streaming(), _exchange_clear_sent_data_from_store(), _exchange_evaluate_response(), _exchange_fill_http_request(), _exchange_prepare_data(), _exchange_store_data_get_content_info(), _exchange_update_store_state(), _finish_json_item(), _generate_correlation_id_string(), _generate_random_boundary(), _generate_token(), _get_payload_from_file(), _get_rsa_private_key(), _get_rsa_public_key(), _initialize(), _initialize_custom_data_meta_fields(), _initialize_meta(), _join_with_dot(), _libcrypto_malloc(), _log_configuration(), _process_registration_response_rsa_3072(), _process_registration_response_shared_secret(), _resize_payload_buffer_if_necessary(), _response_header_callback(), _response_payload_callback(), _save_registration_information(), _set_request_options(), _ssl_context_callback(), _store_add_data(), _store_list_destroy_callback(), custom_data_destroy(), custom_data_initialize(), data_source_configuration_destroy(), data_source_configuration_initialize(), event_destroy(), event_initialize(), event_list_destroy(), event_list_initialize(), file_destroy(), file_initialize(), file_util_fclose_without_log(), file_util_fgets(), file_util_fopen_without_log(), hmac_sha256(), http_client_destroy(), http_client_initialize(), http_client_send(), http_processor_destroy(), http_processor_exchange(), http_processor_get_access_token(), http_processor_initialize(), http_processor_register(), http_processor_stream(), http_processor_update_security_information(), http_request_add_header(), http_request_add_raw_data(), http_request_add_single(), http_request_add_tuple(), http_request_destroy(), http_request_initialize(), http_request_start_tuple_sub_section(), http_response_destroy(), http_response_get_header(), http_response_initialize(), json_from_data_source_configuration_payload(), json_from_event_payload(), json_from_item_meta(), json_from_time_series_payload(), json_util_add_bool(), json_util_add_double(), json_util_add_null(), json_util_add_object(), json_util_add_string(), json_util_add_uint(), json_util_destroy(), json_util_duplicate(), json_util_get_array_item(), json_util_get_object_item(), json_util_has_child(), json_util_initialize(), json_util_parse(), json_util_parse_with_size(), json_util_start_array(), json_util_start_object(), json_util_to_string(), jwt_destroy(), jwt_get_token(), jwt_initialize(), list_add(), list_destroy(), list_destroy_with_content(), list_exist(), list_initialize(), list_next(), list_remove(), list_remove_with_content(), list_reset(), log_util_default_callback(), mcl_communication_destroy(), mcl_communication_exchange(), mcl_communication_get_last_access_token(), mcl_communication_get_last_token_time(), mcl_communication_initialize(), mcl_communication_is_onboarded(), mcl_communication_onboard(), mcl_communication_process(), mcl_communication_rotate_key(), mcl_communication_update_security_information(), mcl_configuration_destroy(), mcl_configuration_initialize(), mcl_data_source_configuration_add_data_point(), mcl_data_source_configuration_add_data_source(), mcl_data_source_configuration_get_id(), mcl_json_util_get_string(), mcl_list_next(), mcl_log_util_convert_error_code_to_string(), mcl_log_util_finalize(), mcl_log_util_initialize(), mcl_new_configuration(), mcl_random_generate_guid(), mcl_store_destroy(), mcl_store_initialize(), mcl_store_new_event(), mcl_time_series_add_value(), mcl_time_series_new_value_set(), memory_allocate(), memory_reallocate(), memory_release(), random_generate_array(), random_generate_guid(), security_generate_rsa_key(), security_handler_destroy(), security_handler_initialize(), security_hash_sha256(), security_rsa_get_modulus_and_exponent(), security_rsa_sign(), storage_load_rsa_registration_information(), storage_load_shared_secret_registration_information(), storage_save_rsa_registration_information(), storage_save_shared_secret_registration_information(), stream_data_initialize(), string_array_add(), string_array_destroy(), string_array_get(), string_array_initialize(), string_array_to_string(), string_compare_with_cstr(), string_concatenate(), string_concatenate_cstr(), string_convert_binary_to_hex(), string_destroy(), string_initialize(), string_initialize_dynamic(), string_initialize_new(), string_initialize_static(), string_release(), string_replace(), string_split(), time_series_destroy(), time_series_initialize(), time_util_convert_to_iso_8601_format(), and time_util_validate_timestamp().

#define MCL_NULL_CHAR_SIZE   1

Definition at line 27 of file definitions.h.

Referenced by http_request_add_single(), and http_request_end_tuple_sub_section().

#define MCL_SIZE_MAX   ((mcl_size_t) - 1)

Definition at line 21 of file definitions.h.

Referenced by list_add().

#define MIN_HTTP_PAYLOAD_SIZE   400

Definition at line 51 of file definitions.h.

Referenced by mcl_communication_initialize().

#define NONCE_SIZE   16

Definition at line 29 of file definitions.h.

#define STRING_CONSTANT (   s)    {s, sizeof(s)/sizeof(s[0]) - 1, MCL_STRING_NOT_COPY_NOT_DESTROY}

Definition at line 135 of file definitions.h.