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... | |
Enumerations | |
enum | ta_e_custom_receipt_formatter_text_type { ta_c_crftt_text, ta_c_crftt_user_id, ta_c_crftt_pos_id, ta_c_crftt_transaction_type, ta_c_crftt_dashed_line, ta_c_crftt_receipt_header, ta_c_crftt_field_act_id, ta_c_crftt_field_acc_per, ta_c_crftt_field_acq_id, ta_c_crftt_field_aid, ta_c_crftt_field_amount, ta_c_crftt_field_amount_dcc, ta_c_crftt_field_amount_other, ta_c_crftt_field_auth_code, ta_c_crftt_field_brand_name, ta_c_crftt_field_currency, ta_c_crftt_field_currency_dcc, ta_c_crftt_field_dcc_disclaimer, ta_c_crftt_field_disclaimer, ta_c_crftt_field_exponent, ta_c_crftt_field_exponent_dcc, ta_c_crftt_field_markup_dcc, ta_c_crftt_field_markup_exponent_dcc, ta_c_crftt_field_card_number_printable_merchant, ta_c_crftt_field_card_number_printable_cardholder, ta_c_crftt_field_rate_dcc, ta_c_crftt_field_rate_exponent_dcc, ta_c_crftt_field_time_stamp_date, ta_c_crftt_field_time_stamp_time, ta_c_crftt_field_trm_id, ta_c_crftt_field_trx_ref_num, ta_c_crftt_field_trx_seq_cnt, ta_c_crftt_field_pos_entry_mode, ta_c_crftt_field_card_expiry_date, ta_c_crftt_field_card_number_enc, ta_c_crftt_field_amount_saldo, ta_c_crftt_field_ecr_seq_cnt, ta_c_crftt_field_number_of_installments, ta_c_crftt_field_installment_disclaimer, ta_c_crftt_field_tender_name, ta_c_crftt_field_tender_or_brand_name, ta_c_crftt_field_markup_dcc_regulated, ta_c_crftt_field_markup_exponent_dcc_regulated, ta_c_crftt_field_rate_dcc_regulated, ta_c_crftt_field_rate_exponent_dcc_regulated, ta_c_crftt_field_original_trans_ref, ta_c_crftt_field_key_pan_receipt_index, ta_c_crftt_field_pan_receipt_dol_index, ta_c_crftt_field_amount_installment_fee, ta_c_crftt_field_amount_installment_first, ta_c_crftt_field_amount_installment_one, ta_c_crftt_field_amount_installment_total, ta_c_crftt_field_amount_reservation, ta_c_crftt_field_amount_tip, ta_c_crftt_field_auth_reslt, ta_c_crftt_field_auth_resp_c, ta_c_crftt_field_auth_resp_text_c, ta_c_crftt_field_clerk_identifier, ta_c_crftt_field_fuel_dispenser_number, ta_c_crftt_field_interest_installment, ta_c_crftt_field_merchant_tid, ta_c_crftt_field_multi_account_index, ta_c_crftt_field_multi_contract_index, ta_c_crftt_field_original_aid, ta_c_crftt_field_original_brand_name, ta_c_crftt_field_original_card_country_code, ta_c_crftt_field_original_card_number_printable, ta_c_crftt_field_original_tender_name, ta_c_crftt_field_posdnumber, ta_c_crftt_field_pan_receipt_dol, ta_c_crftt_field_pre_authorization_exp_date, ta_c_crftt_field_receipt_number, ta_c_crftt_field_shift_number, ta_c_crftt_field_card_product_type, ta_c_crftt_field_account_type, ta_c_crftt_field_surcharge_amount, ta_c_crftt_field_original_trans_seq, ta_c_crftt_field_original_trans_seq_sep, ta_c_crftt_field_balance_exp_date, ta_c_crftt_field_amount_of_goods, ta_c_crftt_field_signature_line, ta_c_crftt_field_amount_due, ta_c_crftt_field_amount_total } |
Custom receipt formatter text types. More... | |
enum | ta_e_custom_receipt_formatter_text_alignment { ta_c_crfta_left, ta_c_crfta_right, ta_c_crfta_center } |
Custom receipt formatter text alignment. | |
enum | ta_e_custom_receipt_formatter_condition { ta_crfc_none, ta_crfc_ecr_info, ta_crfc_eft_info, ta_crfc_signature, ta_crfc_has_values, ta_crfc_has_installment, ta_crfc_dcc, ta_crfc_has_values_no_invalid_fields, ta_crfc_header, ta_crfc_footer, ta_crfc_is_reversal, ta_crfc_has_all_values, ta_crfc_partial_approval, ta_crfc_no_partial_approval, ta_crfc_has_additional_amounts, ta_crfc_ecr_info_with_trans_seq } |
Custom receipt formatter condition. | |
enum | ta_e_custom_receipt_formatter_translated_text { ta_crftt_undefined, ta_crftt_trx_type_credit, ta_crftt_trx_type_purchase, ta_crftt_trx_type_reversal, ta_crftt_attendant_id, ta_crftt_ecr_id, ta_crftt_ecr_seq, ta_crftt_trm_id, ta_crftt_act_id, ta_crftt_aid, ta_crftt_trx_seq_cnt, ta_crftt_trx_curr, ta_crftt_local_curr, ta_crftt_rate, ta_crftt_installment_payment, ta_crftt_no_installments, ta_crftt_trx_ref_no, ta_crftt_original_trans_ref, ta_crftt_auth_code, ta_crftt_total_eft, ta_crftt_cardholder, ta_crftt_merchant, ta_crftt_saldo, ta_crftt_att_ecr_id_seq, ta_crftt_eft_ref_no, ta_crftt_expiration_date, ta_crftt_exp, ta_crftt_trm_act_id, ta_crftt_seq_ref_auth, ta_crftt_epf, ta_crftt_seq_aut, ta_crftt_account_type, ta_crftt_surcharge_amount, ta_crftt_acq_id, ta_crftt_product, ta_crftt_rev_seq_counter, ta_crftt_user_id, ta_crftt_transaction_amount, ta_crftt_amount_eft, ta_crftt_amount_tip, ta_crftt_balance_exp_date, ta_crftt_installment_fee, ta_crftt_amount_installment_total, ta_crftt_installment_first, ta_crftt_installment_one, ta_crftt_installment_interest, ta_crftt_amount_cashback, ta_crftt_markup, ta_crftt_pre_authorization_exp_date, ta_crftt_partial_approval, ta_crftt_approved, ta_crftt_amount_due, ta_crftt_amount_total } |
Custom receipt formatter translated text. | |
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. |