TIM SDK
TIM API C
command_request.h File Reference

Description

Command request.

Object type command_request.

Functions

ta_e_result_code_t ta_command_request_create (ta_object_t *request)
 Create object of type command_request. More...
 
ta_e_result_code_t ta_command_request_get_card_reader (ta_object_t request, ta_e_card_reader_t *card_reader)
 Defines that shall be used for the card commands. More...
 
ta_e_result_code_t ta_command_request_set_card_reader (ta_object_t request, ta_e_card_reader_t card_reader)
 Defines that shall be used for the card commands. More...
 
ta_e_result_code_t ta_command_request_get_order (ta_object_t request, int *order)
 Specifies the order of a CommandRequest in CommandRequestList. More...
 
ta_e_result_code_t ta_command_request_set_order (ta_object_t request, int order)
 Specifies the order of a CommandRequest in CommandRequestList. More...
 
ta_e_result_code_t ta_command_request_get_card_command (ta_object_t request, ta_object_t *card_command)
 Command to send to card. More...
 
ta_e_result_code_t ta_command_request_set_card_command (ta_object_t request, ta_object_t card_command)
 Command to send to card. More...
 
ta_e_result_code_t ta_command_request_get_positive_resource (ta_object_t request, ta_e_resource_id_t *positive_resource)
 If a dialog shall be shown in case of a positive command response. More...
 
ta_e_result_code_t ta_command_request_set_positive_resource (ta_object_t request, ta_e_resource_id_t positive_resource)
 If a dialog shall be shown in case of a positive command response. More...
 
ta_e_result_code_t ta_command_request_get_negative_resource (ta_object_t request, ta_e_resource_id_t *negative_resource)
 If a dialog shall be shown in case of a negative command response. More...
 
ta_e_result_code_t ta_command_request_set_negative_resource (ta_object_t request, ta_e_resource_id_t negative_resource)
 If a dialog shall be shown in case of a negative command response. More...
 
ta_e_result_code_t ta_command_request_get_execution_resource (ta_object_t request, ta_e_resource_id_t *execution_resource)
 If a dialog shall be shown during the execution of a command. More...
 
ta_e_result_code_t ta_command_request_set_execution_resource (ta_object_t request, ta_e_resource_id_t execution_resource)
 If a dialog shall be shown during the execution of a command. More...
 
ta_e_result_code_t ta_command_request_get_pre_resource (ta_object_t request, ta_e_resource_id_t *pre_resource)
 If a dialog shall be shown before sending a card command. More...
 
ta_e_result_code_t ta_command_request_set_pre_resource (ta_object_t request, ta_e_resource_id_t pre_resource)
 If a dialog shall be shown before sending a card command. More...
 
ta_e_result_code_t ta_command_request_get_positive_answers (ta_object_t request, ta_object_t *positive_answers)
 Possible positive answers for a CommandRequest. More...
 
ta_e_result_code_t ta_command_request_set_positive_answers (ta_object_t request, ta_object_t positive_answers)
 Set possible positive answers for a CommandRequest. More...
 

Function Documentation

◆ ta_command_request_create()

ta_e_result_code_t ta_command_request_create ( ta_object_t request)

Create object of type command_request.

Parameters
[out]requestPointer to variable to write created object instance to. Created object instance is retained.
Return values
ta_c_rc_okObject instance has been created and written to request.
ta_c_rc_invalid_argumentrequest is null-pointer.
ta_c_rc_out_of_memoryFailed allocating memory.

◆ ta_command_request_get_card_command()

ta_e_result_code_t ta_command_request_get_card_command ( ta_object_t  request,
ta_object_t card_command 
)

Command to send to card.

Parameters
[in]requestObject instance of type command_request.
[out]card_commandPointer to variable to write object instance to. Object instance is of type string and is not retained. Object instance is ta_invalid_object if value is not set in request.
Return values
ta_c_rc_okObject instance written to card_command.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentcard_command is null-pointer.

◆ ta_command_request_get_card_reader()

ta_e_result_code_t ta_command_request_get_card_reader ( ta_object_t  request,
ta_e_card_reader_t card_reader 
)

Defines that shall be used for the card commands.

Parameters
[in]requestObject instance of type command_request.
[out]card_readerPointer to variable to write value to. Value is ta_c_cr_undefined if value is not set in request.
Return values
ta_c_rc_okObject instance written to card_reader.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentcard_reader is null-pointer.

◆ ta_command_request_get_execution_resource()

ta_e_result_code_t ta_command_request_get_execution_resource ( ta_object_t  request,
ta_e_resource_id_t execution_resource 
)

If a dialog shall be shown during the execution of a command.

Parameters
[in]requestObject instance of type command_request.
[out]execution_resourcePointer to variable to write value to. Value is ta_c_rid_undefined if value is not set in request.
Return values
ta_c_rc_okObject instance written to execution_resource.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentexecution_resource is null-pointer.

◆ ta_command_request_get_negative_resource()

ta_e_result_code_t ta_command_request_get_negative_resource ( ta_object_t  request,
ta_e_resource_id_t negative_resource 
)

If a dialog shall be shown in case of a negative command response.

Parameters
[in]requestObject instance of type command_request.
[out]negative_resourcePointer to variable to write value to. Value is ta_c_rid_undefined if value is not set in request.
Return values
ta_c_rc_okObject instance written to negative_resource.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentnegative_resource is null-pointer.

◆ ta_command_request_get_order()

ta_e_result_code_t ta_command_request_get_order ( ta_object_t  request,
int *  order 
)

Specifies the order of a CommandRequest in CommandRequestList.

Parameters
[in]requestObject instance of type command_request.
[out]orderPointer to variable to write value to. Value is 0 if value is not set in request.
Return values
ta_c_rc_okObject instance written to order.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentorder is null-pointer.

◆ ta_command_request_get_positive_answers()

ta_e_result_code_t ta_command_request_get_positive_answers ( ta_object_t  request,
ta_object_t positive_answers 
)

Possible positive answers for a CommandRequest.

Parameters
[in]requestObject instance of type command_request.
[out]positive_answersPointer to variable to write object instance to. Object instance is of type list and is not retained. The list contains elements of type string.
Return values
ta_c_rc_okObject instance written to positive_answers.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentpositive_answers is null-pointer.

◆ ta_command_request_get_positive_resource()

ta_e_result_code_t ta_command_request_get_positive_resource ( ta_object_t  request,
ta_e_resource_id_t positive_resource 
)

If a dialog shall be shown in case of a positive command response.

Parameters
[in]requestObject instance of type command_request.
[out]positive_resourcePointer to variable to write value to. Value is ta_c_rid_undefined if value is not set in request.
Return values
ta_c_rc_okObject instance written to positive_resource.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentpositive_resource is null-pointer.

◆ ta_command_request_get_pre_resource()

ta_e_result_code_t ta_command_request_get_pre_resource ( ta_object_t  request,
ta_e_resource_id_t pre_resource 
)

If a dialog shall be shown before sending a card command.

Parameters
[in]requestObject instance of type command_request.
[out]pre_resourcePointer to variable to write value to. Value is ta_c_rid_undefined if value is not set in request.
Return values
ta_c_rc_okObject instance written to execution_resource.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentpre_resource is null-pointer.

◆ ta_command_request_set_card_command()

ta_e_result_code_t ta_command_request_set_card_command ( ta_object_t  request,
ta_object_t  card_command 
)

Command to send to card.

Parameters
[in]requestObject instance of type command_request.
[in]card_commandObject instance to set. Object instance can be ta_invalid_object to clear the value in request. If object instance is not ta_invalid_object is has to be of type string.
Return values
ta_c_rc_okObject instance assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentcard_command is not ta_invalid_object and is not of type string.

◆ ta_command_request_set_card_reader()

ta_e_result_code_t ta_command_request_set_card_reader ( ta_object_t  request,
ta_e_card_reader_t  card_reader 
)

Defines that shall be used for the card commands.

Parameters
[in]requestObject instance of type command_request.
[in]card_readerValue to set. Value can be ta_c_cr_undefined to clear the value in request.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.

◆ ta_command_request_set_execution_resource()

ta_e_result_code_t ta_command_request_set_execution_resource ( ta_object_t  request,
ta_e_resource_id_t  execution_resource 
)

If a dialog shall be shown during the execution of a command.

Parameters
[in]requestObject instance of type command_request.
[in]execution_resourceValue to set. Value can be ta_c_rid_undefined to clear the value in request.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.

◆ ta_command_request_set_negative_resource()

ta_e_result_code_t ta_command_request_set_negative_resource ( ta_object_t  request,
ta_e_resource_id_t  negative_resource 
)

If a dialog shall be shown in case of a negative command response.

Parameters
[in]requestObject instance of type command_request.
[in]negative_resourceValue to set. Value can be ta_c_rid_undefined to clear the value in request.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.

◆ ta_command_request_set_order()

ta_e_result_code_t ta_command_request_set_order ( ta_object_t  request,
int  order 
)

Specifies the order of a CommandRequest in CommandRequestList.

Parameters
[in]requestObject instance of type command_request.
[in]orderValue to set.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.

◆ ta_command_request_set_positive_answers()

ta_e_result_code_t ta_command_request_set_positive_answers ( ta_object_t  request,
ta_object_t  positive_answers 
)

Set possible positive answers for a CommandRequest.

Parameters
[in]requestObject instance of type command_request.
[in]positive_answersObject instance to set. Object instance has to be of type list. The list has to contain elements of type string.
Return values
ta_c_rc_okObject instance assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.
ta_c_rc_invalid_argumentpositive_answers is ta_invalid_object.
ta_c_rc_invalid_argumentpositive_answers is not of type list.
ta_c_rc_invalid_argumentElement in positive_answers is ta_invalid_object.
ta_c_rc_invalid_argumentElement in positive_answers is not of type string.

◆ ta_command_request_set_positive_resource()

ta_e_result_code_t ta_command_request_set_positive_resource ( ta_object_t  request,
ta_e_resource_id_t  positive_resource 
)

If a dialog shall be shown in case of a positive command response.

Parameters
[in]requestObject instance of type command_request.
[in]positive_resourceValue to set. Value can be ta_c_rid_undefined to clear the value in request.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.

◆ ta_command_request_set_pre_resource()

ta_e_result_code_t ta_command_request_set_pre_resource ( ta_object_t  request,
ta_e_resource_id_t  pre_resource 
)

If a dialog shall be shown before sending a card command.

Parameters
[in]requestObject instance of type command_request.
[in]pre_resourceValue to set. Value can be ta_c_rid_undefined to clear the value in request.
Return values
ta_c_rc_okValue assigned to request.
ta_c_rc_invalid_argumentrequest is ta_invalid_object.
ta_c_rc_invalid_argumentrequest is not of type command_request.