TIM SDK
TIM API C
|
|
Custom receipt formatter.
Object type custom_receipt_formatter.
Data Structures | |
struct | ta_s_custom_receipt_formatter_text_element |
Custom receipt formatter text element definition. More... | |
struct | ta_s_custom_receipt_formatter_line_format |
Custom receipt formatter line definition. More... | |
struct | ta_s_custom_receipt_formatter_configuration |
Custom receipt formatter configuration. More... | |
Typedefs | |
typedef enum ta_e_custom_receipt_formatter_text_type | ta_e_custom_receipt_formatter_text_type_t |
Custom receipt formatter text types. | |
typedef enum ta_e_custom_receipt_formatter_text_alignment | ta_e_custom_receipt_formatter_text_alignment_t |
Custom receipt formatter text alignment. | |
typedef enum ta_e_custom_receipt_formatter_condition | ta_e_custom_receipt_formatter_condition_t |
Custom receipt formatter condition. | |
typedef struct ta_s_custom_receipt_formatter_text_element | ta_s_custom_receipt_formatter_text_element_t |
Custom receipt formatter text element definition. More... | |
typedef struct ta_s_custom_receipt_formatter_line_format | ta_s_custom_receipt_formatter_line_format_t |
Custom receipt formatter line definition. More... | |
typedef struct ta_s_custom_receipt_formatter_configuration | ta_s_custom_receipt_formatter_configuration_t |
Custom receipt formatter configuration. More... | |
Functions | |
ta_e_result_code_t | ta_custom_receipt_formatter_create (ta_object_t *formatter, const ta_s_custom_receipt_formatter_configuration_t *configuration) |
Create custom receipt formatter. More... | |
ta_e_result_code_t | ta_normal_receipt_formatter_create (ta_object_t *formatter) |
Create normal receipt format. More... | |
ta_e_result_code_t | ta_compact_receipt_formatter_create (ta_object_t *formatter) |
Create compact receipt format. More... | |
ta_e_result_code_t | ta_super_compact_receipt_formatter_create (ta_object_t *formatter) |
Create super compact receipt format. More... | |
ta_e_result_code_t | ta_ultra_compact_receipt_formatter_create (ta_object_t *formatter) |
Create ultra compact receipt format. More... | |
typedef struct ta_s_custom_receipt_formatter_configuration ta_s_custom_receipt_formatter_configuration_t |
Custom receipt formatter configuration.
Used by ta_custom_receipt_formatter_create to initialize formatter. After the object has been created the struct data is not required anymore.
typedef struct ta_s_custom_receipt_formatter_line_format ta_s_custom_receipt_formatter_line_format_t |
Custom receipt formatter line definition.
Contains array of text elements.
typedef struct ta_s_custom_receipt_formatter_text_element ta_s_custom_receipt_formatter_text_element_t |
Custom receipt formatter text element definition.
Can be static text or dynamic content. Used during construction of object.
Custom receipt formatter text types.
ta_e_result_code_t ta_compact_receipt_formatter_create | ( | ta_object_t * | formatter | ) |
Create compact receipt format.
Formats transaction receipts using compact receipt format.
Caller retains a reference to the created instance. While assigning to a terminal instance the terminal instance retains the reference. The user can release the reference directly afterwards. In this case the formatter is destroyed once no terminal instance requires the formatter anymore.
[out] | formatter | Pointer to variable to write created object instance to. Created object instance is retained. Object is of type custom_receipt_formatter |
ta_c_rc_ok | Object instance has been created and written to formatter. |
ta_c_rc_invalid_argument | formatter is null-pointer. |
ta_c_rc_out_of_memory | Failed allocating memory. |
ta_e_result_code_t ta_custom_receipt_formatter_create | ( | ta_object_t * | formatter, |
const ta_s_custom_receipt_formatter_configuration_t * | configuration | ||
) |
Create custom receipt formatter.
Formats transaction receipts using string formating definition. The definition is required to be valid memory location only during construction time. The receipt formatted stores the information internally during construction time. After the object has been constructed the memory locations can become invalid.
Caller retains a reference to the created instance. While assigning to a terminal instance the terminal instance retains the reference. The user can release the reference directly afterwards. In this case the formatter is destroyed once no terminal instance requires the formatter anymore.
[out] | formatter | Pointer to variable to write created object instance to. Created object instance is retained. |
[in] | configuration | Pointer to struct containinig formatter configuration. |
ta_c_rc_ok | Object instance has been created and written to formatter. |
ta_c_rc_invalid_argument | formatter is null-pointer. |
ta_c_rc_invalid_argument | configuration is null-pointer. |
ta_c_rc_out_of_memory | Failed allocating memory. |
ta_e_result_code_t ta_normal_receipt_formatter_create | ( | ta_object_t * | formatter | ) |
Create normal receipt format.
Formats transaction receipts using normal receipt format.
Caller retains a reference to the created instance. While assigning to a terminal instance the terminal instance retains the reference. The user can release the reference directly afterwards. In this case the formatter is destroyed once no terminal instance requires the formatter anymore.
[out] | formatter | Pointer to variable to write created object instance to. Created object instance is retained. Object is of type custom_receipt_formatter |
ta_c_rc_ok | Object instance has been created and written to formatter. |
ta_c_rc_invalid_argument | formatter is null-pointer. |
ta_c_rc_out_of_memory | Failed allocating memory. |
ta_e_result_code_t ta_super_compact_receipt_formatter_create | ( | ta_object_t * | formatter | ) |
Create super compact receipt format.
Formats transaction receipts using super compact receipt format.
Caller retains a reference to the created instance. While assigning to a terminal instance the terminal instance retains the reference. The user can release the reference directly afterwards. In this case the formatter is destroyed once no terminal instance requires the formatter anymore.
[out] | formatter | Pointer to variable to write created object instance to. Created object instance is retained. Object is of type custom_receipt_formatter |
ta_c_rc_ok | Object instance has been created and written to formatter. |
ta_c_rc_invalid_argument | formatter is null-pointer. |
ta_c_rc_out_of_memory | Failed allocating memory. |
ta_e_result_code_t ta_ultra_compact_receipt_formatter_create | ( | ta_object_t * | formatter | ) |
Create ultra compact receipt format.
Formats transaction receipts using ultra compact receipt format.
Caller retains a reference to the created instance. While assigning to a terminal instance the terminal instance retains the reference. The user can release the reference directly afterwards. In this case the formatter is destroyed once no terminal instance requires the formatter anymore.
[out] | formatter | Pointer to variable to write created object instance to. Created object instance is retained. Object is of type custom_receipt_formatter |
ta_c_rc_ok | Object instance has been created and written to formatter. |
ta_c_rc_invalid_argument | formatter is null-pointer. |
ta_c_rc_out_of_memory | Failed allocating memory. |