Tizen Native API  5.5
Autofill client

The Autofill client API provides the functions for sending data to the autofill service and receiving the data previously entered by the user from the autofill service.

Required Header

#include <autofill.h>

Overview

Autofill is a feature that allows you to fill out the data previously entered by the user such as email, account and address in a text input field. email, account and address in a text input field. The Autofill client API provides the functions for sending data to the autofill service and receiving the data previously entered by the user from the autofill service.

Functions

int autofill_create (autofill_h *ah)
 Creates a handle for autofill.
int autofill_destroy (autofill_h ah)
 Destroys an autofill.
int autofill_connect (autofill_h ah, autofill_connection_status_changed_cb callback, void *user_data)
 Connects to autofill daemon.
int autofill_auth_info_request (autofill_h ah, autofill_view_info_h vi)
 Requests of authentication information.
int autofill_auth_info_set_received_cb (autofill_h ah, autofill_auth_info_received_cb callback, void *user_data)
 Sets the callback to receive the authentication information.
int autofill_auth_info_unset_received_cb (autofill_h ah)
 Unsets the callback to receive the authentication information.
int autofill_fill_request (autofill_h ah, autofill_view_info_h vi)
 Sends fill request to fill out each input form.
int autofill_cancel_fill_request (autofill_h ah, autofill_view_info_h vi)
 Cancels autofill request to fill out each input form.
int autofill_fill_response_set_received_cb (autofill_h ah, autofill_fill_response_received_cb callback, void *user_data)
 Sets the callback to receive autofill fill response.
int autofill_fill_response_unset_received_cb (autofill_h ah)
 Unsets the callback to receive autofill fill response.
int autofill_commit (autofill_h ah, autofill_save_view_info_h vi)
 Sends the autofill save view info.
int autofill_error_info_set_received_cb (autofill_h ah, autofill_error_info_received_cb callback, void *user_data)
 Sets the callback to receive the error information.
int autofill_error_info_unset_received_cb (autofill_h ah)
 Unsets the callback to receive the error information.

Typedefs

typedef struct autofill_s * autofill_h
 The autofill handle.
typedef void(* autofill_connection_status_changed_cb )(autofill_h ah, autofill_connection_status_e status, void *user_data)
 Called when the connection status is changed.
typedef void(* autofill_fill_response_received_cb )(autofill_h ah, autofill_fill_response_h fill_response_h, void *user_data)
 Called when receiving autofill fill response data.
typedef void(* autofill_auth_info_received_cb )(autofill_h ah, autofill_auth_info_h auth_info, void *user_data)
 Called when receiving the authentication information.
typedef void(* autofill_error_info_received_cb )(autofill_h ah, autofill_error_info_h error_info, void *user_data)
 Called when receiving the error information.

Typedef Documentation

typedef void(* autofill_auth_info_received_cb)(autofill_h ah, autofill_auth_info_h auth_info, void *user_data)

Called when receiving the authentication information.

Since :
5.5
Remarks:
ah should not be freed and can be used only in the callback.
auth_info should not be freed and can be used only in the callback.
Parameters:
[in]ahThe autofill handle
[in]auth_infoThe autofill authentication information handle
[in]user_dataThe user data passed from the callback function
See also:
autofill_auth_info_set_received_cb()

Called when the connection status is changed.

Since :
5.5
Remarks:
ah should not be freed and can be used only in the callback.
Parameters:
[in]ahThe autofill handle
[in]statusThe connection status
[in]user_dataThe user data passed from the callback function
See also:
autofill_connect()
typedef void(* autofill_error_info_received_cb)(autofill_h ah, autofill_error_info_h error_info, void *user_data)

Called when receiving the error information.

Since :
5.5
Remarks:
ah should not be freed and can be used only in the callback.
error_info should not be freed and can be used only in the callback.
Parameters:
[in]ahThe autofill handle
[in]error_infoThe autofill error information handle
[in]user_dataThe user data passed from the callback function
See also:
autofill_error_info_set_received_cb()
typedef void(* autofill_fill_response_received_cb)(autofill_h ah, autofill_fill_response_h fill_response_h, void *user_data)

Called when receiving autofill fill response data.

Since :
5.5
Remarks:
ah should not be freed and can be used only in the callback.
fill_response_h should not be freed and can be used only in the callback.
Parameters:
[in]ahThe autofill handle
[in]fill_response_hThe autofill fill response handle
[in]user_dataThe user data to be passed to the callback function
See also:
autofill_fill_response_set_received_cb()
typedef struct autofill_s* autofill_h

The autofill handle.

Since :
5.5

Enumeration Type Documentation

Enumeration of connection status.

Since :
5.5
Enumerator:
AUTOFILL_CONNECTION_STATUS_CONNECTED 

Connected

AUTOFILL_CONNECTION_STATUS_DISCONNECTED 

Disconnected

AUTOFILL_CONNECTION_STATUS_REJECTED 

Rejected


Function Documentation

Requests of authentication information.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]viThe autofill view info handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OPERATION_FAILEDOperation failure
int autofill_auth_info_set_received_cb ( autofill_h  ah,
autofill_auth_info_received_cb  callback,
void *  user_data 
)

Sets the callback to receive the authentication information.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]callbackThe callback function to register
[in]user_dataThe user data to be passed to the callback function
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_auth_info_unset_received_cb()

Unsets the callback to receive the authentication information.

Since :
5.5
Parameters:
[in]ahThe autofill handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_auth_info_set_received_cb()

Cancels autofill request to fill out each input form.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]viThe autofill view info handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OPERATION_FAILEDOperation failure
See also:
autofill_fill_request()

Sends the autofill save view info.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]viThe autofill save view info handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OPERATION_FAILEDOperation failure
int autofill_connect ( autofill_h  ah,
autofill_connection_status_changed_cb  callback,
void *  user_data 
)

Connects to autofill daemon.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]callbackThe callback function to register
[in]user_dataThe user data to be passed to the callback function
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OPERATION_FAILEDOperation failure
int autofill_create ( autofill_h ah)

Creates a handle for autofill.

Since :
5.5
Remarks:
If the function succeeds, ah handle must be released with autofill_destroy().
Parameters:
[out]ahThe autofill handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OUT_OF_MEMORYOut of memory
See also:
autofill_destroy()

Destroys an autofill.

Since :
5.5
Parameters:
[in]ahThe autofill handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_create()
int autofill_error_info_set_received_cb ( autofill_h  ah,
autofill_error_info_received_cb  callback,
void *  user_data 
)

Sets the callback to receive the error information.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]callbackThe callback function to register
[in]user_dataThe user data to be passed to the callback function
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_error_info_unset_received_cb()

Unsets the callback to receive the error information.

Since :
5.5
Parameters:
[in]ahThe autofill handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_error_info_set_received_cb()

Sends fill request to fill out each input form.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]viThe autofill view info handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
AUTOFILL_ERROR_OPERATION_FAILEDOperation failure
See also:
autofill_cancel_fill_request()

Sets the callback to receive autofill fill response.

Since :
5.5
Parameters:
[in]ahThe autofill handle
[in]callbackThe callback function to register
[in]user_dataThe user data to be passed to the callback function
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter
See also:
autofill_fill_response_unset_received_cb()

Unsets the callback to receive autofill fill response.

Since :
5.5
Parameters:
[in]ahThe autofill handle
Returns:
0 on success, otherwise a negative error value
Return values:
AUTOFILL_ERROR_NONENo error
AUTOFILL_ERROR_INVALID_PARAMETERInvalid parameter